Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ repos:
rev: v0.21.0
hooks:
- id: yamlfmt
- repo: https://github.com/tox-dev/pyproject-fmt
rev: v2.27.0
hooks:
- id: pyproject-fmt
# See https://pre-commit.ci/
ci:
autoupdate_schedule: weekly
Expand Down
154 changes: 71 additions & 83 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,114 +1,102 @@
[build-system]
requires = ["flit_core>=3.2", "flit_scm", "wheel"]
build-backend = "flit_scm:buildapi"
requires = [ "flit-core>=3.2", "flit-scm", "wheel" ]

[project]
name = "threadmill"
readme = "README.md"
keywords = [ "Django", "tasks", "worker" ]
license = { file = "LICENSE" }
authors = [
{ name = "Johannes Maron", email = "johannes@maron.family" },
]
readme = "README.md"
license = { file = "LICENSE" }
keywords = ["Django", "tasks", "worker"]
dynamic = ["version", "description"]
requires-python = ">=3.14"
classifiers = [
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Environment :: Web Environment",
"License :: OSI Approved :: BSD License",
"Framework :: Django",
"Framework :: Django :: 6.1",
"Intended Audience :: Developers",
"Operating System :: Microsoft :: Windows",
"License :: OSI Approved :: BSD License",
"Operating System :: MacOS :: MacOS X",
"Operating System :: Microsoft :: Windows",
"Operating System :: POSIX",
"Topic :: Communications :: Email",
"Topic :: Text Processing :: Markup :: Markdown",
"Topic :: Software Development",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.14",
"Framework :: Django",
"Framework :: Django :: 6.1",
"Topic :: Communications :: Email",
"Topic :: Software Development",
"Topic :: Text Processing :: Markup :: Markdown",
]
requires-python = ">=3.14"
dependencies = ["django>=6.0"]

[project.optional-dependencies]
redis = ["redis>=5.0"]
inspector = [
"textual>=8.2.7",
dynamic = [ "description", "version" ]
dependencies = [ "django>=6" ]
optional-dependencies.inspector = [
"textual>=8.2.7",
]

[project.urls]
optional-dependencies.redis = [ "redis>=5" ]
urls.Changelog = "https://github.com/codingjoe/threadmill/releases"
urls.Documentation = "https://github.com/codingjoe/threadmill/"
urls.Funding = "https://github.com/sponsors/codingjoe"
# https://packaging.python.org/en/latest/specifications/well-known-project-urls/#well-known-labels
Homepage = "https://github.com/codingjoe/threadmill"
Changelog = "https://github.com/codingjoe/threadmill/releases"
Source = "https://github.com/codingjoe/threadmill"
Releasenotes = "https://github.com/codingjoe/threadmill/releases/latest"
Documentation = "https://github.com/codingjoe/threadmill/"
Issues = "https://github.com/codingjoe/threadmill/issues"
Funding = "https://github.com/sponsors/codingjoe"

[tool.flit.module]
name = "threadmill"

[tool.setuptools_scm]
write_to = "threadmill/_version.py"

[tool.pytest.ini_options]
minversion = "6.1a1"
addopts = "--cov --cov-report=xml --cov-report=term --tb=short -rxs --benchmark-autosave --benchmark-group-by=fullname --benchmark-min-rounds=10"
testpaths = ["tests"]
DJANGO_SETTINGS_MODULE = "tests.testapp.settings"
asyncio_mode = "auto"
markers = [
"benchmark: mark benchmark tests.",
]

[tool.coverage.run]
source = ["threadmill"]

[tool.coverage.report]
show_missing = true
skip_covered = true

[tool.ruff]
src = ["threadmill", "tests"]

[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
"I", # isort
"S", # flake8-bandit
"D", # pydocstyle
"UP", # pyupgrade
"B", # flake8-bugbear
"C", # flake8-comprehensions
]

ignore = ["B904", "D1", "E501", "S101"]

[tool.ruff.lint.isort]
combine-as-imports = true
split-on-trailing-comma = true
section-order = ["future", "standard-library", "third-party", "first-party", "local-folder"]
force-wrap-aliases = true
known-first-party = ["threadmill", "tests"]

[tool.ruff.lint.pydocstyle]
convention = "pep257"
urls.Homepage = "https://github.com/codingjoe/threadmill"
urls.Issues = "https://github.com/codingjoe/threadmill/issues"
urls.Releasenotes = "https://github.com/codingjoe/threadmill/releases/latest"
urls.Source = "https://github.com/codingjoe/threadmill"

[dependency-groups]
dev = [
{ include-group = "test" },
]
test = [
"pytest",
"pytest-benchmark",
"pytest-asyncio",
"pytest-benchmark",
"pytest-cov",
"pytest-django",
"redis>=5.0",
"redis>=5",
]

[tool.setuptools_scm]
write_to = "threadmill/_version.py"

[tool.flit]
module.name = "threadmill"

[tool.ruff]
src = [ "tests", "threadmill" ]
lint.select = [
"B", # flake8-bugbear
"C", # flake8-comprehensions
"D", # pydocstyle
"E", # pycodestyle errors
"F", # pyflakes
"I", # isort
"S", # flake8-bandit
"UP", # pyupgrade
"W", # pycodestyle warnings
]
lint.ignore = [ "B904", "D1", "E501", "S101" ]
lint.isort.combine-as-imports = true
lint.isort.force-wrap-aliases = true
lint.isort.known-first-party = [ "threadmill", "tests" ]
lint.isort.section-order = [ "future", "standard-library", "third-party", "first-party", "local-folder" ]
lint.isort.split-on-trailing-comma = true
lint.pydocstyle.convention = "pep257"

[tool.pytest]
ini_options.minversion = "6.1a1"
ini_options.testpaths = [ "tests" ]
ini_options.addopts = """\
--cov --cov-report=xml --cov-report=term --tb=short -rxs --benchmark-autosave --benchmark-group-by=fullname \
--benchmark-min-rounds=10\
"""
ini_options.markers = [
"benchmark: mark benchmark tests.",
]
ini_options.asyncio_mode = "auto"
ini_options.DJANGO_SETTINGS_MODULE = "tests.testapp.settings"

[tool.coverage]
run.source = [ "threadmill" ]
report.show_missing = true
report.skip_covered = true
Loading