Skip to content

Commit 4516745

Browse files
committed
2 parents d021417 + f1350e4 commit 4516745

5 files changed

Lines changed: 44 additions & 11 deletions

File tree

.coveragerc

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ disable_warnings =
1212
[report]
1313
show_missing = True
1414
exclude_also =
15-
# jaraco/skeleton#97
16-
@overload
15+
# Exclude common false positives per
16+
# https://coverage.readthedocs.io/en/latest/excluding.html#advanced-exclusion
17+
# Ref jaraco/skeleton#97 and jaraco/skeleton#135
18+
class .*\bProtocol\):
1719
if TYPE_CHECKING:

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/astral-sh/ruff-pre-commit
3-
rev: v0.1.8
3+
rev: v0.5.6
44
hooks:
55
- id: ruff
66
- id: ruff-format

mypy.ini

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
[mypy]
2-
ignore_missing_imports = True
3-
# required to support namespace packages
4-
# https://github.com/python/mypy/issues/14057
2+
# Is the project well-typed?
3+
strict = False
4+
5+
# Early opt-in even when strict = False
6+
warn_unused_ignores = True
7+
warn_redundant_casts = True
8+
enable_error_code = ignore-without-code
9+
10+
# Support namespace packages per https://github.com/python/mypy/issues/14057
511
explicit_package_bases = True
12+
13+
# Disable overload-overlap due to many false-positives
14+
disable_error_code = overload-overlap

pyproject.toml

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,16 +32,12 @@ Source = "https://github.com/python/importlib_resources"
3232
test = [
3333
# upstream
3434
"pytest >= 6, != 8.1.*",
35-
"pytest-checkdocs >= 2.4",
36-
"pytest-cov",
37-
"pytest-mypy",
38-
"pytest-enabler >= 2.2",
39-
"pytest-ruff >= 0.2.1; sys_platform != 'cygwin'",
4035

4136
# local
4237
"zipp >= 3.17",
4338
"jaraco.test >= 5.4",
4439
]
40+
4541
doc = [
4642
# upstream
4743
"sphinx >= 3.5",
@@ -56,4 +52,26 @@ doc = [
5652
# local
5753
]
5854

55+
check = [
56+
"pytest-checkdocs >= 2.4",
57+
"pytest-ruff >= 0.2.1; sys_platform != 'cygwin'",
58+
]
59+
60+
cover = [
61+
"pytest-cov",
62+
]
63+
64+
enabler = [
65+
"pytest-enabler >= 2.2",
66+
]
67+
68+
type = [
69+
# upstream
70+
"pytest-mypy",
71+
72+
# local
73+
]
74+
75+
76+
5977
[tool.setuptools_scm]

tox.ini

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ commands =
88
usedevelop = True
99
extras =
1010
test
11+
check
12+
cover
13+
enabler
14+
type
1115

1216
[testenv:diffcov]
1317
description = run tests and check that diff from main is covered

0 commit comments

Comments
 (0)