-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
- Loading branch information
1 parent
6e3da99
commit 1245513
Showing
2 changed files
with
50 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,8 +12,10 @@ readme = "README.rst" | |
keywords = [ | ||
"Django", | ||
] | ||
license = {file = "LICENSE"} | ||
authors = [{name = "Mark Walker", email = "[email protected]"}] | ||
license = { file = "LICENSE" } | ||
authors = [ | ||
{ name = "Mark Walker", email = "[email protected]" }, | ||
] | ||
requires-python = ">=3.10" | ||
classifiers = [ | ||
"Development Status :: 4 - Beta", | ||
|
@@ -34,60 +36,60 @@ classifiers = [ | |
"Typing :: Typed", | ||
] | ||
dependencies = [ | ||
"Django>=3.2", | ||
"django>=3.2", | ||
"nh3", | ||
] | ||
[project.urls] | ||
Changelog = "https://github.com/marksweb/django-nh3/blob/main/CHANGELOG.rst" | ||
Mastodon = "https://fosstodon.org/@markwalker" | ||
Repository = "https://github.com/marksweb/django-nh3" | ||
Twitter = "https://twitter.com/markwalker_" | ||
|
||
urls.Changelog = "https://github.com/marksweb/django-nh3/blob/main/CHANGELOG.rst" | ||
|
||
urls.Mastodon = "https://fosstodon.org/@markwalker" | ||
|
||
urls.Repository = "https://github.com/marksweb/django-nh3" | ||
|
||
urls.Twitter = "https://twitter.com/markwalker_" | ||
|
||
[tool.setuptools.packages.find] | ||
where = ["src"] | ||
where = [ | ||
"src", | ||
] | ||
|
||
[tool.ruff] | ||
extend-exclude = [ | ||
"**migrations/**", | ||
".env", | ||
".ruff_cache", | ||
] | ||
|
||
# https://beta.ruff.rs/docs/configuration/ | ||
select = [ | ||
"E", # pycodestyle errors | ||
"W", # pycodestyle warnings | ||
"F", # pyflakes | ||
"I", # isort | ||
"C", # flake8-comprehensions | ||
"B", # flake8-bugbear | ||
"Q", # flake8-quotes | ||
"E", # pycodestyle errors | ||
"W", # pycodestyle warnings | ||
"F", # pyflakes | ||
"I", # isort | ||
"C", # flake8-comprehensions | ||
"B", # flake8-bugbear | ||
"Q", # flake8-quotes | ||
"PLE", # pylint error | ||
"PLR", # pylint refactor | ||
"PLW", # pylint warning | ||
"UP", # pyupgrade | ||
] | ||
|
||
extend-exclude = [ | ||
".ruff_cache", | ||
".env", | ||
"**migrations/**", | ||
"UP", # pyupgrade | ||
] | ||
|
||
ignore = [ | ||
"B006", # Do not use mutable data structures for argument defaults | ||
"PLR0913", # Too many arguments to function call, | ||
"B006", # Do not use mutable data structures for argument defaults | ||
"PLR0913", # Too many arguments to function call, | ||
] | ||
|
||
[tool.ruff.per-file-ignores] | ||
"__init__.py" = [ | ||
"F401" # unused-import | ||
isort.combine-as-imports = true | ||
# Preserve types, even if a file imports `from __future__ import annotations`. | ||
pyupgrade.keep-runtime-typing = true | ||
per-file-ignores."__init__.py" = [ | ||
"F401", # unused-import | ||
] | ||
"src/django_nh3/forms.py" = [ | ||
"UP035", # import-replacements - breaks type hint Callable | ||
per-file-ignores."src/django_nh3/forms.py" = [ | ||
"UP035", # import-replacements - breaks type hint Callable | ||
] | ||
|
||
[tool.ruff.isort] | ||
combine-as-imports = true | ||
|
||
[tool.ruff.pyupgrade] | ||
# Preserve types, even if a file imports `from __future__ import annotations`. | ||
keep-runtime-typing = true | ||
|
||
[tool.pytest] | ||
DJANGO_SETTINGS_MODULE = "tests.settings" | ||
django_find_project = false | ||
|
@@ -103,10 +105,16 @@ django_find_project = false | |
[tool.coverage.run] | ||
branch = true | ||
parallel = true | ||
source = ["django_nh3", "tests"] | ||
source = [ | ||
"django_nh3", | ||
"tests", | ||
] | ||
|
||
[tool.coverage.paths] | ||
source = ["src", ".tox/py*/**/site-packages"] | ||
source = [ | ||
"src", | ||
".tox/py*/**/site-packages", | ||
] | ||
|
||
[tool.coverage.report] | ||
show_missing = true | ||
|