Skip to content

Commit 307e56a

Browse files
Config/use dev deps (#1260)
* Add explicit dev deps for pre-commits * Fix typo
1 parent f04d177 commit 307e56a

5 files changed

Lines changed: 129 additions & 19 deletions

File tree

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,12 @@ repos:
3434
args: [--pytest-test-first]
3535
priority: 0
3636
- repo: https://github.com/abravalheri/validate-pyproject
37-
rev: v0.23
37+
rev: v0.24.1
3838
hooks:
3939
- id: validate-pyproject
4040
priority: 0
4141
- repo: https://github.com/tox-dev/pyproject-fmt
42-
rev: v2.5.0
42+
rev: v2.11.1
4343
hooks:
4444
- id: pyproject-fmt
4545
args: [--max-supported-python=3.14]

pyproject.toml

Lines changed: 20 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -55,14 +55,17 @@ scripts.usethis = "usethis.__main__:app"
5555
[dependency-groups]
5656
dev = [
5757
"basedpyright>=1.36.2",
58+
"codespell>=2.4.1",
5859
"datamodel-code-generator[http]>=0.35.0",
5960
"deptry>=0.23.0",
6061
"import-linter>=2.3",
6162
"jinja2>=3.1.6",
6263
"prek>=0.2.23",
6364
"pyinstrument>=5.1.1",
65+
"pyproject-fmt>=2.11.1",
6466
"ruff>=0.14.3",
6567
"ty>=0.0.1a25",
68+
"validate-pyproject>=0.24.1",
6669
]
6770
test = [
6871
"click>=8.1.8",
@@ -100,6 +103,11 @@ exclude = [
100103
[tool.hatch.build.hooks.vcs]
101104
version-file = "src/usethis/_version.py"
102105

106+
[tool.uv]
107+
required-version = ">=0.8.18" # Sync with README
108+
default-groups = [ "test", "dev", "doc" ]
109+
link-mode = "symlink"
110+
103111
[tool.ruff]
104112
line-length = 88
105113

@@ -147,6 +155,7 @@ lint.flake8-type-checking.strict = true
147155
lint.pydocstyle.convention = "google"
148156

149157
[tool.codespell]
158+
skip = [ "site" ]
150159
ignore-words-list = [ "edn" ]
151160

152161
[tool.pyproject-fmt]
@@ -184,6 +193,17 @@ exclude_also = [
184193
]
185194
omit = [ "*/pytest-of-*/*", "*/_temp/*" ]
186195

196+
[tool.ty]
197+
environment.python-platform = "all"
198+
rules.type-assertion-failure = "ignore"
199+
200+
[[tool.ty.overrides]]
201+
include = [ "src/usethis/_integrations/file/**" ]
202+
rules.invalid-argument-type = "ignore"
203+
rules.invalid-return-type = "ignore"
204+
rules.invalid-assignment = "ignore"
205+
rules.possibly-missing-attribute = "ignore"
206+
187207
[tool.basedpyright]
188208
ignore = [ "src/usethis/_version.py" ]
189209
failOnWarnings = true
@@ -216,22 +236,6 @@ reportUnusedFunction = false
216236
reportUnusedCallResult = false
217237
reportUnusedParameter = false
218238

219-
[tool.ty]
220-
environment.python-platform = "all"
221-
rules.type-assertion-failure = "ignore"
222-
223-
[[tool.ty.overrides]]
224-
include = [ "src/usethis/_integrations/file/**" ]
225-
rules.invalid-argument-type = "ignore"
226-
rules.invalid-return-type = "ignore"
227-
rules.invalid-assignment = "ignore"
228-
rules.possibly-missing-attribute = "ignore"
229-
230-
[tool.uv]
231-
required-version = ">=0.8.18" # Sync with README
232-
default-groups = [ "test", "dev", "doc" ]
233-
link-mode = "symlink"
234-
235239
[tool.importlinter]
236240
root_packages = [ "usethis" ]
237241

requirements.txt

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,9 @@ click==8.1.8 \
169169
# import-linter
170170
# mkdocs
171171
# typer
172+
codespell==2.4.1 \
173+
--hash=sha256:299fcdcb09d23e81e35a671bbe746d5ad7e8385972e65dbb833a2eaac33c01e5 \
174+
--hash=sha256:3dadafa67df7e4a3dbf51e0d7315061b80d265f9552ebd699b3dd6834b47e425
172175
colorama==0.4.6 \
173176
--hash=sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44 \
174177
--hash=sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6
@@ -263,6 +266,10 @@ exceptiongroup==1.2.2 ; python_full_version < '3.11' \
263266
# via
264267
# anyio
265268
# pytest
269+
fastjsonschema==2.21.2 \
270+
--hash=sha256:1c797122d0a86c5cace2e54bf4e819c36223b552017172f32c5c024a6b77e463 \
271+
--hash=sha256:b1eb43748041c880796cd077f1a07c3d94e93ae84bba5ed36800a33554ae05de
272+
# via validate-pyproject
266273
genson==1.3.0 \
267274
--hash=sha256:468feccd00274cc7e4c09e84b08704270ba8d95232aa280f65b986139cec67f7 \
268275
--hash=sha256:e02db9ac2e3fd29e65b5286f7135762e2cd8a986537c075b06fc5f1517308e37
@@ -758,6 +765,23 @@ pymdown-extensions==10.19.1 \
758765
--hash=sha256:4969c691009a389fb1f9712dd8e7bd70dcc418d15a0faf70acb5117d022f7de8 \
759766
--hash=sha256:e8698a66055b1dc0dca2a7f2c9d0ea6f5faa7834a9c432e3535ab96c0c4e509b
760767
# via mkdocs-material
768+
pyproject-fmt==2.11.1 \
769+
--hash=sha256:08ccf565172179fc7f35a90f4541f68abcdbef7e7a4ea35fcead44f8cabe3e3a \
770+
--hash=sha256:0abae947f93cca80108675c025cb67b96a434f7a33148e3f7945e3009db0d073 \
771+
--hash=sha256:2679527bcbd973f1fc1b0fb31ca84455c3fa10199e776184ff125cd6b5157392 \
772+
--hash=sha256:27a9af1fc8d2173deb7a0bbb8c368a585e7817bcbba6acf00922b73c76c8ee23 \
773+
--hash=sha256:2daf29e4958c310c27ce7750741ef60f79b2f4164df26b1f2bdd063f2beddf4c \
774+
--hash=sha256:44b1edad216b33817d2651a15fb2793807fd7c9cfff1ce66d565c4885b89640e \
775+
--hash=sha256:533da20593e9201320eb6ec939f108c5a1baac141538fd0d5e09a08cf25951bc \
776+
--hash=sha256:5bf986b016eb157b30531d0f1036430023db0195cf2d6fd24e4b43cbc02c0da5 \
777+
--hash=sha256:86f4ebc71d658b848bd14da5f2d2f156a238687e5c9adc0e787ecbf925fd24b1 \
778+
--hash=sha256:8fb86748e061ee9b788fbc93b67c4f2e29fef4b82ece565a00af548d919e0dcd \
779+
--hash=sha256:97b6ba9923975667fab130c23bfd8ead66c4cdea4b66ae238de860a06afbb108 \
780+
--hash=sha256:a2dc64e7d048f32b504504fa1ed3285c81dcf7d97e014b382ede8e437b42855a \
781+
--hash=sha256:a3d38b570bdeabe7b3b27e7aa2798b1091b7259c4ca4080de83e5145ba65b11e \
782+
--hash=sha256:b16ce0874ef2aee219a2c0dacd7c0ce374562c19937bd9c767093ade91e5e452 \
783+
--hash=sha256:f8b184c0eda81022af915694a941b4eecf871be8fc23483a72fa4283c49f2eca \
784+
--hash=sha256:f9950376a9996f07b2b58b8b2ad64023f404f73c2cbc99c216b1add6f33f6cee
761785
pytest==8.3.5 \
762786
--hash=sha256:c69214aa47deac29fad6c2a4f590b9c4a9fdb16a403176fe154b79c0b4d4d820 \
763787
--hash=sha256:f4efe70cc14e511565ac476b57c279e12a855b11f48f212af1080ef2263d3845
@@ -938,6 +962,10 @@ termcolor==3.1.0 \
938962
--hash=sha256:591dd26b5c2ce03b9e43f391264626557873ce1d379019786f99b0c2bee140aa \
939963
--hash=sha256:6a6dd7fbee581909eeec6a756cff1d7f7c376063b14e4a298dc4980309e55970
940964
# via pytest-sugar
965+
toml-fmt-common==1.1.0 \
966+
--hash=sha256:92a956c4abf9c14e72d51e4c23149b2596a84ac0c347484e7c36008807e2e0a3 \
967+
--hash=sha256:e4ba8f13e5fe25cfe0bfc60342ad7deb91c741fd31f2e5522e6a51bfbf1427d3
968+
# via pyproject-fmt
941969
tomli==2.2.1 ; python_full_version < '3.12' \
942970
--hash=sha256:023aa114dd824ade0100497eb2318602af309e5a55595f76b626d6d9f3b7b0a6 \
943971
--hash=sha256:02abe224de6ae62c19f090f68da4e27b10af2b93213d36cf44e6e1c5abd19fdd \
@@ -978,6 +1006,7 @@ tomli==2.2.1 ; python_full_version < '3.12' \
9781006
# deptry
9791007
# import-linter
9801008
# pytest
1009+
# toml-fmt-common
9811010
tomlkit==0.13.3 \
9821011
--hash=sha256:430cf247ee57df2b94ee3fbe588e71d362a941ebb545dec29b53961d61add2a1 \
9831012
--hash=sha256:c89c649d79ee40629a9fda55f8ace8c6a1b42deb912b2a8fd8d942ddadb606b0
@@ -1031,6 +1060,9 @@ urllib3==2.6.2 \
10311060
--hash=sha256:016f9c98bb7e98085cb2b4b17b87d2c702975664e4f060c6532e64d1c1a5e797 \
10321061
--hash=sha256:ec21cddfe7724fc7cb4ba4bea7aa8e2ef36f607a4bab81aa6ce42a13dc3f03dd
10331062
# via requests
1063+
validate-pyproject==0.24.1 \
1064+
--hash=sha256:b7b05fa9117204c9c4606ab317acd095b18d1bfc78fb7dc8cc06f77d0582ca2d \
1065+
--hash=sha256:e182fc51354add988e5bee6fc06ceb327832a78d921730fc618275e5b29e6b71
10341066
watchdog==6.0.0 \
10351067
--hash=sha256:07df1fdd701c5d4c8e55ef6cf55b8f0120fe1aef7ef39a1c6fc6bc2e606d517a \
10361068
--hash=sha256:20ffe5b202af80ab4266dcd3e91aae72bf2da48c0d33bdb15c66658e685e94e2 \

src/usethis/_tool/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -491,7 +491,7 @@ def _add_config_item(
491491
break
492492
used_file_managers = new_file_managers
493493

494-
# Now, use the highest-prority file manager to add the config
494+
# Now, use the highest-priority file manager to add the config
495495
(used_file_manager, *_) = used_file_managers
496496

497497
if not config_item.force and entry.keys in used_file_manager:

uv.lock

Lines changed: 74 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)