Skip to content

Commit

Permalink
tell mypy to only check as python 3.9
Browse files Browse the repository at this point in the history
otherwise it defaults to 3.8 which causes issues d/t the import
re-defining

Signed-off-by: Grant Ramsay <[email protected]>
  • Loading branch information
seapagan committed Aug 18, 2024
1 parent 0897cef commit b312dc3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/mypy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ jobs:
path: "."
mypy_flags:
"--install-types --non-interactive --config-file pyproject.toml
--ignore-missing-imports --strict"
--ignore-missing-imports --strict --python-version 3.9"
requirements_file: "requirements-dev.txt"
python_version: "3.8"
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,9 @@ known-first-party = ["simple_toml_settings"]
[tool.ruff.lint.pyupgrade]
keep-runtime-typing = true

[tool.mypy]
python_version = "3.9"

[[tool.mypy.overrides]]
disable_error_code = ["method-assign", "no-untyped-def", "attr-defined"]
module = "tests.*"
1 change: 1 addition & 0 deletions src/core.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Main core of the application."""
# mypy: python_version=3.9

from __future__ import annotations

Expand Down

0 comments on commit b312dc3

Please sign in to comment.