|
28 | 28 | nox.options.sessions = ( |
29 | 29 | "pre-commit", |
30 | 30 | "safety", |
31 | | - # "mypy", |
| 31 | + "mypy", |
32 | 32 | "tests", |
33 | 33 | "typeguard", |
34 | 34 | "xdoctest", |
@@ -146,15 +146,15 @@ def safety(session: Session) -> None: |
146 | 146 | session.run("safety", "check", "--full-report", f"--file={requirements}") |
147 | 147 |
|
148 | 148 |
|
149 | | -# @session(python=python_versions) |
150 | | -# def mypy(session: Session) -> None: |
151 | | -# """Type-check using mypy.""" |
152 | | -# args = session.posargs or ["src", "tests", "docs/conf.py"] |
153 | | -# session.install(".") |
154 | | -# session.install("mypy", "pytest", "types-requests", "types-PyYAML") |
155 | | -# session.run("mypy", *args) |
156 | | -# if not session.posargs: |
157 | | -# session.run("mypy", f"--python-executable={sys.executable}", "noxfile.py") |
| 149 | +@session(python=python_versions) |
| 150 | +def mypy(session: Session) -> None: |
| 151 | + """Type-check using mypy.""" |
| 152 | + args = session.posargs or ["src", "tests", "docs/conf.py"] |
| 153 | + session.install(".") |
| 154 | + session.install("mypy", "pytest", "types-requests", "types-PyYAML") |
| 155 | + session.run("mypy", *args) |
| 156 | + if not session.posargs: |
| 157 | + session.run("mypy", f"--python-executable={sys.executable}", "noxfile.py") |
158 | 158 |
|
159 | 159 |
|
160 | 160 | @session(python=python_versions) |
|
0 commit comments