@@ -61,17 +61,11 @@ python = ["3.9", "3.10", "3.11", "3.12"]
61
61
62
62
[tool .hatch .envs .pre-commit ]
63
63
dependencies = [
64
- " bandit" ,
65
- " black" ,
66
- " flake8" ,
67
- " flake8-bugbear == 22.*" ,
68
- " flake8-docstrings" ,
69
- " isort" ,
70
- " pep8-naming" ,
64
+ " ruff" ,
71
65
" pre-commit" ,
72
66
" pre-commit-hooks" ,
73
- " pyupgrade" ,
74
67
]
68
+
75
69
[tool .hatch .envs .pre-commit .scripts ]
76
70
run = [
77
71
" pre-commit run --all-files --show-diff-on-failure" ,
@@ -92,6 +86,7 @@ dependencies = [
92
86
" pytest" ,
93
87
" freezegun" ,
94
88
]
89
+
95
90
[tool .hatch .envs .mypy .scripts ]
96
91
run = [
97
92
" mypy src/ tests/ docs/conf.py" ,
@@ -105,6 +100,7 @@ dependencies = [
105
100
" pygments" ,
106
101
" freezegun" ,
107
102
]
103
+
108
104
[tool .hatch .envs .tests .scripts ]
109
105
run = [
110
106
" coverage run --parallel -m pytest"
@@ -114,11 +110,13 @@ run = [
114
110
dependencies = [
115
111
" coverage[toml]" ,
116
112
]
113
+
117
114
[tool .hatch .envs .coverage .scripts ]
118
115
run = [
119
116
" - coverage combine" ,
120
117
" coverage report" ,
121
118
]
119
+
122
120
run-xml = [
123
121
" coverage xml"
124
122
]
@@ -131,6 +129,7 @@ dependencies = [
131
129
" typeguard" ,
132
130
" pygments" ,
133
131
]
132
+
134
133
[tool .hatch .envs .typeguard .scripts ]
135
134
run = [
136
135
" pytest --typeguard-packages=human_readable" ,
@@ -140,6 +139,7 @@ run = [
140
139
dependencies = [
141
140
" xdoctest[colors]" ,
142
141
]
142
+
143
143
[tool .hatch .envs .xdoctest .scripts ]
144
144
run = [
145
145
" python -m xdoctest human_readable all" ,
@@ -151,6 +151,7 @@ dependencies = [
151
151
" furo" ,
152
152
" myst-parser" ,
153
153
]
154
+
154
155
[tool .hatch .envs .docs-build .scripts ]
155
156
run = [
156
157
" rm -rf docs/_build" ,
@@ -164,6 +165,7 @@ dependencies = [
164
165
" furo" ,
165
166
" myst-parser" ,
166
167
]
168
+
167
169
[tool .hatch .envs .docs .scripts ]
168
170
run = [
169
171
" rm -rf docs/_build" ,
@@ -182,7 +184,18 @@ source = ["human_readable", "tests"]
182
184
show_missing = true
183
185
fail_under = 100
184
186
185
- [tool .isort ]
187
+ [tool .ruff ]
188
+ line-length = 80
189
+
190
+ [tool .ruff .lint ]
191
+ select = [" B" , " B9" , " C" , " D" , " E" , " F" , " N" , " W" ]
192
+ ignore = [" E203" , " E501" , " W503" , " B905" ]
193
+ per-file-ignores = [ " times.py:N806" ]
194
+
195
+ [tool .ruff .lint .mccabe ]
196
+ max-complexity = 10
197
+
198
+ [tool .ruff .lint .isort ]
186
199
profile = " black"
187
200
force_single_line = true
188
201
lines_after_imports = 2
@@ -195,7 +208,6 @@ show_column_numbers = true
195
208
show_error_codes = true
196
209
show_error_context = true
197
210
198
-
199
211
[[tool .mypy .overrides ]]
200
212
module = [" pytest_mock" ]
201
213
ignore_missing_imports = true
0 commit comments