diff --git a/pyproject.toml b/pyproject.toml index 8da0baf..9f45836 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -11,25 +11,21 @@ requires = [ "versioningit", ] -[tool.versioningit.vcs] -method = "git" -default-tag = "0.0.0" - [project] name = "verlib2" description = "A standalone variant of packaging.version, without anything else." readme = "README.md" -requires-python = ">=3.6" -license = {text = "Apache License 2.0"} keywords = [ "distutils", "packaging", "version", ] -authors = [{name = "Donald Stufft", email = "donald@stufft.io"}] +license = { text = "Apache License 2.0" } maintainers = [ - {name = "Andreas Motl", email = "andreas.motl@panodata.org"}, + { name = "Andreas Motl", email = "andreas.motl@panodata.org" }, ] +authors = [ { name = "Donald Stufft", email = "donald@stufft.io" } ] +requires-python = ">=3.6" classifiers = [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Developers", @@ -56,8 +52,7 @@ dynamic = [ dependencies = [ ] -[project.optional-dependencies] -develop = [ +optional-dependencies.develop = [ "black<25", "mypy<1.12", "poethepoet<1", @@ -65,21 +60,56 @@ develop = [ "ruff<0.7", "validate-pyproject<0.21", ] -release = [ +optional-dependencies.release = [ "build<2", "twine<6", ] -test = [ +optional-dependencies.test = [ "pretend<2", "pytest<9", "pytest-cov<6", ] +urls.Repository = "https://github.com/pyveci/verlib2" + [tool.setuptools] # https://setuptools.pypa.io/en/latest/userguide/package_discovery.html -packages = ["verlib2"] +packages = [ "verlib2" ] + +[tool.ruff] +#line-length = 120 + +lint.select = [ + # Builtins + "A", + # Bugbear + "B", + # comprehensions + "C4", + # Pycodestyle + "E", + # eradicate + "ERA", + # Pyflakes + "F", + # isort + "I", + # pandas-vet + "PD", + # return + "RET", + # Bandit + "S", + # print + "T20", + "W", + # flake8-2020 + "YTT", +] + +lint.ignore = [ "RET505" ] + +lint.per-file-ignores."tests/*" = [ "S101" ] # Use of `assert` detected -[project.urls] -Repository = "https://github.com/pyveci/verlib2" [tool.pytest.ini_options] minversion = "2.0" addopts = """ @@ -88,7 +118,7 @@ addopts = """ """ log_level = "DEBUG" log_cli_level = "DEBUG" -testpaths = ["tests"] +testpaths = [ "tests" ] xfail_strict = true markers = [ ] @@ -96,56 +126,23 @@ markers = [ [tool.coverage.run] branch = true omit = [ - "tests/*", + "tests/*", ] [tool.coverage.report] -exclude_lines = ["pragma: no cover", "@abc.abstractmethod", "@abc.abstractproperty"] +exclude_lines = [ "pragma: no cover", "@abc.abstractmethod", "@abc.abstractproperty" ] fail_under = 0 show_missing = true [tool.mypy] -packages = ["verlib2"] +packages = [ "verlib2" ] strict = true show_error_codes = true -enable_error_code = ["ignore-without-code", "redundant-expr", "truthy-bool"] - -[tool.ruff] -#line-length = 120 - -select = [ - # Bandit - "S", - # Bugbear - "B", - # Builtins - "A", - # comprehensions - "C4", - # eradicate - "ERA", - # flake8-2020 - "YTT", - # isort - "I", - # pandas-vet - "PD", - # print - "T20", - # Pycodestyle - "E", - "W", - # Pyflakes - "F", - # return - "RET", -] - -ignore = ["RET505"] - -[tool.ruff.per-file-ignores] -"tests/*" = ["S101"] # Use of `assert` detected +enable_error_code = [ "ignore-without-code", "redundant-expr", "truthy-bool" ] +[tool.versioningit.vcs] +method = "git" +default-tag = "0.0.0" # =================== # Tasks configuration @@ -173,7 +170,7 @@ test-fast = [ { cmd = "pytest -m 'not slow'" }, ] build = { cmd = "python -m build" } -check = ["lint", "test"] +check = [ "lint", "test" ] release = [ { cmd = "python -m build" },