@@ -78,15 +78,14 @@ pre-commit = "*"
7878pylint = " *"
7979basedmypy = " *"
8080basedpyright = " *"
81- typing_extensions = " >=4.12.2,<4.13"
8281# import dependencies for mypy:
8382array-api-strict = " *"
8483numpy = " *"
8584pytest = " *"
8685
8786[tool .pixi .feature .lint .tasks ]
8887pre-commit-install = { cmd = " pre-commit install" }
89- pre-commit = { cmd = " pre-commit run -v -- all-files --show-diff-on-failure " }
88+ pre-commit = { cmd = " pre-commit run -- all-files" }
9089mypy = { cmd = " mypy" , cwd = " ." }
9190pylint = { cmd = [" pylint" , " array_api_extra" ], cwd = " src" }
9291pyright = { cmd = " basedpyright" , cwd = " ." }
@@ -99,21 +98,22 @@ array-api-strict = "*"
9998numpy = " *"
10099
101100[tool .pixi .feature .tests .tasks ]
102- tests = { cmd = " pytest" }
103- tests-ci = { cmd = " pytest -ra --cov --cov-report=xml --cov-report=term --durations=20" }
101+ tests = { cmd = " pytest -v " }
102+ tests-ci = { cmd = " pytest -v - ra --cov --cov-report=xml --cov-report=term --durations=20" }
104103tests-vendor = { cmd = " pytest vendor_tests" }
104+ coverage = { cmd = [" coverage" , " html" ], depends-on = [" tests-ci" ] }
105+ open-coverage = { cmd = [" open" , " htmlcov/index.html" ], depends-on = [" coverage" ] }
105106
106107[tool .pixi .feature .docs .dependencies ]
107108sphinx = " >=7.0"
108109furo = " >=2023.08.17"
109110myst-parser = " >=0.13"
110111sphinx-copybutton = " *"
111112sphinx-autodoc-typehints = " *"
112- typing_extensions = " >=4.12.2,<4.13"
113113
114114[tool .pixi .feature .docs .tasks ]
115115docs = { cmd = [" sphinx-build" , " ." , " build/" ], cwd = " docs" }
116- open-docs = { cmd = [" open" , " build/index.html" ], cwd = " docs" }
116+ open-docs = { cmd = [" open" , " build/index.html" ], cwd = " docs" , depends-on = [ " docs " ] }
117117
118118[tool .pixi .feature .dev .dependencies ]
119119ipython = " *"
@@ -189,6 +189,7 @@ run.source = ["array_api_extra"]
189189report.exclude_also = [
190190 ' \.\.\.' ,
191191 ' if typing.TYPE_CHECKING:' ,
192+ ' if TYPE_CHECKING:' ,
192193]
193194
194195
@@ -237,11 +238,16 @@ target-version = "py310"
237238[tool .ruff .lint ]
238239extend-select = [
239240 " B" , # flake8-bugbear
241+ " F" , # Pyflakes
240242 " I" , # isort
243+ " E" , # Pycodestyle
244+ " W" , # Pycodestyle
245+ " N" , # pep8-naming
241246 " ARG" , # flake8-unused-arguments
242247 " C4" , # flake8-comprehensions
243248 " EM" , # flake8-errmsg
244249 " ICN" , # flake8-import-conventions
250+ " ISC" , # flake8-implicit-str-concat
245251 " G" , # flake8-logging-format
246252 " PGH" , # pygrep-hooks
247253 " PIE" , # flake8-pie
@@ -257,11 +263,15 @@ extend-select = [
257263 " EXE" , # flake8-executable
258264 " NPY" , # NumPy specific rules
259265 " PD" , # pandas-vet
266+ " UP" , # Pyupgrade
260267]
261268ignore = [
262269 " PLR09" , # Too many <...>
263270 " PLR2004" , # Magic value used in comparison
264271 " ISC001" , # Conflicts with formatter
272+ " N801" , # Class name should use CapWords convention
273+ " N802" , # Function name should be lowercase
274+ " N806" , # Variable in function should be lowercase
265275 " PD008" , # Use `.loc` instead of `.at`
266276]
267277
0 commit comments