Skip to content

Commit

Permalink
Merge pull request #60 from sudlab/ns-rse/49-52-mypy
Browse files Browse the repository at this point in the history
  • Loading branch information
ns-rse authored Nov 20, 2024
2 parents f94c379 + 0486e32 commit e62a4b7
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,14 @@ repos:
- id: python-check-blanket-noqa
- id: python-check-blanket-type-ignore
- id: python-check-mock-methods

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.13.0
hooks:
- id: mypy
files: isoslam
args: ["--ignore-without-code", "--redundant-expr", "--truthy-bool"]

- repo: local
hooks:
- id: pylint
Expand Down
15 changes: 15 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ docs = [
dev = [
"black",
"ipython",
"mypy",
"pre-commit",
"pylint",
"pyupgrade",
Expand Down Expand Up @@ -255,3 +256,17 @@ override_SS05 = [ # override SS05 to allow docstrings starting with these words
"^Assess ",
"^Access ",
]

[tool.mypy]
files = [
"isoslam",
"tests"
]
python_version = "3.9"
strict = true
enable_error_code = ["ignore-without-code", "redundant-expr", "truthy-bool"]
warn_unreachable = true

[[tool.mypy.overrides]]
module = [ "numpy.*", ]
ignore_missing_imports = true

0 comments on commit e62a4b7

Please sign in to comment.