2
2
requires = [" setuptools>=45" , " wheel" , " setuptools_scm[toml]>=6.0" ]
3
3
build-backend = " setuptools.build_meta"
4
4
5
-
6
5
[tool .setuptools_scm ]
7
6
write_to = " src/pytask_stata/_version.py"
8
7
9
-
10
8
[tool .mypy ]
11
9
files = [" src" , " tests" ]
12
10
check_untyped_defs = true
@@ -17,54 +15,36 @@ no_implicit_optional = true
17
15
warn_redundant_casts = true
18
16
warn_unused_ignores = true
19
17
20
-
21
18
[[tool .mypy .overrides ]]
22
19
module = " tests.*"
23
20
disallow_untyped_defs = false
24
21
ignore_errors = true
25
22
26
-
27
23
[tool .ruff ]
28
24
target-version = " py38"
29
- select = [" ALL" ]
30
25
fix = true
31
- extend-ignore = [
32
- " I" , # ignore isort
33
- " TRY" ,
34
- # Numpy docstyle
35
- " D107" ,
36
- " D203" ,
37
- " D212" ,
38
- " D213" ,
39
- " D402" ,
40
- " D413" ,
41
- " D415" ,
42
- " D416" ,
43
- " D417" ,
44
- # Others.
45
- " D404" , # Do not start module docstring with "This".
46
- " RET504" , # unnecessary variable assignment before return.
47
- " S101" , # raise errors for asserts.
48
- " B905" , # strict parameter for zip that was implemented in py310.
49
- " ANN101" , # type annotating self
50
- " ANN102" , # type annotating cls
51
- " FBT" , # flake8-boolean-trap
52
- " EM" , # flake8-errmsg
53
- " ANN401" , # flake8-annotate typing.Any
54
- " PD" , # pandas-vet
55
- " COM812" , # trailing comma missing, but black takes care of that
56
- ]
26
+ unsafe-fixes = true
57
27
28
+ [tool .ruff .lint ]
29
+ select = [" ALL" ]
30
+ ignore = [
31
+ " ANN101" ,
32
+ " ANN102" ,
33
+ " ANN401" , # flake8-annotate typing.Any
34
+ " COM812" , # Comply with ruff-format.
35
+ " ISC001" , # Comply with ruff-format.
36
+ ]
58
37
59
- [tool .ruff .per-file-ignores ]
60
- "tests/*" = [" D" , " ANN" ]
38
+ [tool .ruff .lint . per-file-ignores ]
39
+ "tests/*" = [" D" , " ANN" , " S101 " ]
61
40
"__init__.py" = [" D104" ]
62
41
42
+ [tool .ruff .lint .isort ]
43
+ force-single-line = true
63
44
64
- [tool .ruff .pydocstyle ]
45
+ [tool .ruff .lint . pydocstyle ]
65
46
convention = " numpy"
66
47
67
-
68
48
[tool .pytest .ini_options ]
69
49
# Do not add src since it messes with the loading of pytask-parallel as a plugin.
70
50
testpaths = [" tests" ]
0 commit comments