Skip to content

Commit ffcc0bb

Browse files
committed
Update config
1 parent cc3369e commit ffcc0bb

File tree

4 files changed

+32
-25
lines changed

4 files changed

+32
-25
lines changed

.github/workflows/test.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
uses: codecov/[email protected]
4242
with:
4343
flags: ${{ matrix.os }}
44-
name: "${{ matrix.os }} Python ${{ matrix.python-version }}"
44+
name: ${{ matrix.os }} Python ${{ matrix.python-version }}
4545

4646
success:
4747
needs: test

.pre-commit-config.yaml

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
repos:
22
- repo: https://github.com/astral-sh/ruff-pre-commit
3-
rev: v0.5.0
3+
rev: v0.6.5
44
hooks:
55
- id: ruff
66
args: [--exit-non-zero-on-fix]
77

88
- repo: https://github.com/psf/black-pre-commit-mirror
9-
rev: 24.4.2
9+
rev: 24.8.0
1010
hooks:
1111
- id: black
1212
exclude: ^html/
@@ -26,7 +26,7 @@ repos:
2626
- id: trailing-whitespace
2727

2828
- repo: https://github.com/python-jsonschema/check-jsonschema
29-
rev: 0.28.6
29+
rev: 0.29.2
3030
hooks:
3131
- id: check-github-workflows
3232
- id: check-renovate
@@ -37,17 +37,17 @@ repos:
3737
- id: actionlint
3838

3939
- repo: https://github.com/tox-dev/pyproject-fmt
40-
rev: 2.1.3
40+
rev: 2.2.3
4141
hooks:
4242
- id: pyproject-fmt
4343

4444
- repo: https://github.com/abravalheri/validate-pyproject
45-
rev: v0.18
45+
rev: v0.19
4646
hooks:
4747
- id: validate-pyproject
4848

4949
- repo: https://github.com/tox-dev/tox-ini-fmt
50-
rev: 1.3.1
50+
rev: 1.4.0
5151
hooks:
5252
- id: tox-ini-fmt
5353

pyproject.toml

+15-16
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,8 @@ keywords = [
1313
"osm openstreetmap tiles visualization",
1414
]
1515
license = { text = "MIT" }
16-
maintainers = [
17-
{ name = "Hugo van Kemenade" },
18-
]
19-
authors = [
20-
{ name = "Colin Bick and Contributors", email = "[email protected]" },
21-
]
16+
maintainers = [ { name = "Hugo van Kemenade" } ]
17+
authors = [ { name = "Colin Bick and Contributors", email = "[email protected]" } ]
2218
requires-python = ">=3.9"
2319
classifiers = [
2420
"Intended Audience :: Developers",
@@ -33,9 +29,7 @@ classifiers = [
3329
"Programming Language :: Python :: Implementation :: PyPy",
3430
"Topic :: Software Development :: Documentation",
3531
]
36-
dynamic = [
37-
"version",
38-
]
32+
dynamic = [ "version" ]
3933
optional-dependencies.tests = [
4034
"coverage",
4135
"pillow>=9.1",
@@ -62,30 +56,35 @@ lint.select = [
6256
"EM", # flake8-errmsg
6357
"F", # pyflakes errors
6458
"I", # isort
59+
"ICN", # flake8-import-conventions
6560
"ISC", # flake8-implicit-str-concat
6661
"LOG", # flake8-logging
6762
"PGH", # pygrep-hooks
63+
"PYI", # flake8-pyi
6864
"RUF022", # unsorted-dunder-all
6965
"RUF100", # unused noqa (yesqa)
7066
"UP", # pyupgrade
7167
"W", # pycodestyle warnings
7268
"YTT", # flake8-2020
7369
]
74-
lint.extend-ignore = [
70+
lint.ignore = [
7571
"E203", # Whitespace before ':'
7672
"E221", # Multiple spaces before operator
7773
"E226", # Missing whitespace around arithmetic operator
7874
"E241", # Multiple spaces after ','
7975
]
80-
lint.isort.known-first-party = [
81-
"osmviz",
82-
]
83-
lint.isort.required-imports = [
84-
"from __future__ import annotations",
85-
]
76+
lint.flake8-import-conventions.aliases.datetime = "dt"
77+
lint.flake8-import-conventions.banned-from = [ "datetime" ]
78+
lint.isort.known-first-party = [ "osmviz" ]
79+
lint.isort.required-imports = [ "from __future__ import annotations" ]
8680

8781
[tool.pyproject-fmt]
8882
max_supported_python = "3.13"
8983

9084
[tool.pytest.ini_options]
9185
addopts = "-W error::DeprecationWarning"
86+
filterwarnings = [
87+
# Python <= 3.11
88+
"ignore:sys.monitoring isn't available, using default core:coverage.exceptions.CoverageWarning",
89+
]
90+
testpaths = [ "tests" ]

tox.ini

+10-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,16 @@ pass_env =
1212
FORCE_COLOR
1313
commands =
1414
coverage erase
15-
{envpython} -m pytest --cov osmviz --cov test --cov-append test/unit {posargs}
16-
{envpython} -m pytest --cov osmviz --cov test --cov-append test/functional/test_manager.py {posargs}
15+
{envpython} -m pytest \
16+
--cov osmviz \
17+
--cov test \
18+
--cov-append test/unit \
19+
{posargs}
20+
{envpython} -m pytest \
21+
--cov osmviz \
22+
--cov test \
23+
--cov-append test/functional/test_manager.py \
24+
{posargs}
1725
coverage xml
1826

1927
[testenv:lint]

0 commit comments

Comments
 (0)