Skip to content

Commit

Permalink
ensure backward compat with py3.8
Browse files Browse the repository at this point in the history
  • Loading branch information
jacanchaplais committed Mar 4, 2024
1 parent b56ab5f commit 797b499
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,18 @@ repos:
hooks:
- id: pyupgrade
args: ["--py38-plus"]
- repo: https://github.com/netromdk/vermin
rev: v1.6.0
hooks:
- id: vermin
args: [
'-t=3.8-',
'--violations',
'--eval-annotations',
'--backports=typing',
'--backports=typing_extensions',
'--backports=enum',
]
- repo: https://github.com/PyCQA/autoflake
rev: v2.1.1
hooks:
Expand Down
2 changes: 1 addition & 1 deletion graphicle/transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
_complex_unpack = op.attrgetter("real", "imag")


def _cos_sin(angle: float) -> tuple[float, float]:
def _cos_sin(angle: float) -> ty.Tuple[float, float]:
"""Returns a tuple containing the sine and cosine of an angle."""
return _complex_unpack(cmath.rect(1.0, angle))

Expand Down

0 comments on commit 797b499

Please sign in to comment.