Switch from poetry to uv
Use the PEP 735 "[dependency-groups]" (here: "dev", "test", "docs") instead of Poetry's "dev" group, and `uv_build` as the build backend. Replace poetry.lock with uv.lock. Also, adapt CI and the README.
This commit is contained in:
parent
afb17b61da
commit
355dfd993f
1 changed files with 3811 additions and 5637 deletions
|
|
@ -1,7 +1,7 @@
|
|||
[build-system]
|
||||
|
||||
build-backend = "poetry.core.masonry.api"
|
||||
requires = ["poetry-core>=2.0.0,<3.0.0"]
|
||||
build-backend = "uv_build"
|
||||
requires = ["uv_build>=0.12.20,<0.13"]
|
||||
|
||||
|
||||
|
||||
|
|
@ -68,6 +68,45 @@ repository = "https://code.webartifex.de/alexander/velofy"
|
|||
|
||||
|
||||
|
||||
[dependency-groups]
|
||||
|
||||
dev = [
|
||||
# Task Runners
|
||||
"nox>=2026.10.20",
|
||||
"pre-commit>=4.7.0,<5",
|
||||
|
||||
# Code Formatters
|
||||
"autoflake>=2.4.0,<3",
|
||||
"black>=25.12.0,<26",
|
||||
"isort>=9.0.2,<10",
|
||||
|
||||
# Code Analyzers
|
||||
"flake8>=7.5.0,<8",
|
||||
"flake8-annotations>=3.3.1,<4",
|
||||
"flake8-black>=0.5.0,<0.6",
|
||||
"flake8-pyproject>=1.2.4,<2",
|
||||
"flake8-pytest-style>=2.2.0,<3",
|
||||
"mypy>=2.4.1,<3",
|
||||
]
|
||||
|
||||
test = [
|
||||
"factory-boy>=3.3.3,<4",
|
||||
"Faker>=40.63.0,<41",
|
||||
"packaging>=26.4", # Used to test the packaged version
|
||||
"pytest-cov>=7.1.0,<8",
|
||||
"pytest-env>=1.8.8,<2",
|
||||
"pytest-mock>=3.17.0,<4",
|
||||
"pytest>=9.2.0,<10",
|
||||
"xdoctest[optional]>=1.3.2,<2",
|
||||
]
|
||||
|
||||
docs = [
|
||||
"sphinx>=9.2.0,<10",
|
||||
"sphinx-autodoc-typehints>=3.17.7,<4",
|
||||
]
|
||||
|
||||
|
||||
|
||||
[tool.black]
|
||||
|
||||
target-version = ["py313"]
|
||||
|
|
@ -387,41 +426,6 @@ ignore_missing_imports = true
|
|||
|
||||
|
||||
|
||||
[tool.poetry.group.dev.dependencies]
|
||||
|
||||
# Task Runners
|
||||
nox = ">=2026.10.20"
|
||||
pre-commit = ">=4.7.0,<5"
|
||||
|
||||
# Code Formatters
|
||||
autoflake = ">=2.4.0,<3"
|
||||
black = ">=25.12.0,<26"
|
||||
isort = ">=9.0.2,<10"
|
||||
|
||||
# Code Analyzers
|
||||
flake8 = ">=7.5.0,<8"
|
||||
flake8-annotations = ">=3.3.1,<4"
|
||||
flake8-black = ">=0.5.0,<0.6"
|
||||
flake8-pyproject = ">=1.2.4,<2"
|
||||
flake8-pytest-style = ">=2.2.0,<3"
|
||||
mypy = ">=2.4.1,<3"
|
||||
|
||||
# Test Suite
|
||||
Faker = ">=40.63.0,<41"
|
||||
factory-boy = ">=3.3.3,<4"
|
||||
packaging = ">=26.4" # Used to test the packaged version
|
||||
pytest = ">=9.2.0,<10"
|
||||
pytest-cov = ">=7.1.0,<8"
|
||||
pytest-env = ">=1.8.8,<2"
|
||||
pytest-mock = ">=3.17.0,<4"
|
||||
xdoctest = { version=">=1.3.2,<2", extras=["optional"] }
|
||||
|
||||
# Documentation
|
||||
sphinx = ">=9.2.0,<10"
|
||||
sphinx-autodoc-typehints = ">=3.17.7,<4"
|
||||
|
||||
|
||||
|
||||
[tool.pytest.ini_options]
|
||||
# Source: https://docs.pytest.org/en/stable/reference/reference.html#ini-options-ref
|
||||
|
||||
|
|
@ -444,3 +448,12 @@ markers = [
|
|||
"e2e: non-db and non-r integration tests",
|
||||
"r: (integration) tests using rpy2",
|
||||
]
|
||||
|
||||
|
||||
|
||||
[tool.uv]
|
||||
# Source: https://docs.astral.sh/uv/reference/settings/
|
||||
|
||||
# `uv sync` installs all [dependency-groups] into the local develop environment
|
||||
# whereas the `nox` sessions install only the groups they need
|
||||
default-groups = "all"
|
||||
|
|
|
|||
Loading…
Reference in a new issue