pyproject.toml
This file
Path
pyproject.toml
214 lines · 5.8 KiB · TOML
Last changed by
👷 Configure `ty` to exit with error code on warnings (#1657)Sofie Van Landeghembefore adoptionf96a4a1
History of this fileTake it
The walk stopped after 200 commits: lines older than cb0e472 point at it.
📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 1–13why, one step back1[build-system]2requires = ["pdm-backend"]3build-backend = "pdm.backend"45[project]6name = "typer"7license = "MIT"8license-files = ["LICENSE"]9dynamic = ["version"]10description = "Typer, build great CLIs. Easy to code. Based on Python type hints."11authors = [12 {name = "Sebastián Ramírez", email = "tiangolo@gmail.com"},13]➖ Drop support for Python 3.9 (#1546)Sebastián Ramírezbefore adoption28035df
line 14why, one step back14requires-python = ">=3.10"📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 15–35why, one step back15classifiers = [16 "Intended Audience :: Information Technology",17 "Intended Audience :: System Administrators",18 "Operating System :: OS Independent",19 "Programming Language :: Python :: 3",20 "Programming Language :: Python",21 "Topic :: Software Development :: Libraries :: Application Frameworks",22 "Topic :: Software Development :: Libraries :: Python Modules",23 "Topic :: Software Development :: Libraries",24 "Topic :: Software Development",25 "Typing :: Typed",26 "Development Status :: 4 - Beta",27 "Intended Audience :: Developers",28 "Programming Language :: Python :: 3 :: Only",29 "Programming Language :: Python :: 3.10",30 "Programming Language :: Python :: 3.11",31 "Programming Language :: Python :: 3.12",32 "Programming Language :: Python :: 3.13",33 "Programming Language :: Python :: 3.14",34]35dependencies = [➖ Drop support for Python 3.9 (#1546)Sebastián Ramírezbefore adoption28035df
line 36why, one step back36 "click >= 8.2.1",💥 Make `typer-slim` a shallow wrapper around `typer`, always requiring `rich` and `shellingham` (#1522)Sofie Van Landeghembefore adoptionb66a370
line 37why, one step back37 "shellingham >=1.3.0",👷 Run tests with lower bound uv sync, update minimum dependencies (#1526)Motov Yuriibefore adoption459030e
line 38why, one step back38 "rich >=12.3.0",📝 Add reference (code API) docs (#1504)Sofie Van Landeghembefore adoption2d529b2
line 39why, one step back39 "annotated-doc >=0.0.2",📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 40–49why, one step back40]41readme = "README.md"4243[project.urls]44Homepage = "https://github.com/fastapi/typer"45Documentation = "https://typer.tiangolo.com"46Repository = "https://github.com/fastapi/typer"47Issues = "https://github.com/fastapi/typer/issues"48Changelog = "https://typer.tiangolo.com/release-notes/"49💥 Make `typer-slim` a shallow wrapper around `typer`, always requiring `rich` and `shellingham` (#1522)Sofie Van Landeghembefore adoptionb66a370
lines 50–51why, one step back50[project.scripts]51typer = "typer.cli:main"📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 52–56why, one step back5253[dependency-groups]54dev = [55 { include-group = "tests" },56 { include-group = "docs" },📌 Update internal dependency limits (#1529)Sebastián Ramírezbefore adoption69d48e0
line 57why, one step back57 "prek >=0.3.2",📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 58–59why, one step back58]59docs = [📌 Update internal dependency limits (#1529)Sebastián Ramírezbefore adoption69d48e0
lines 60–70why, one step back60 "cairosvg >=2.8.2",61 "griffe-typingdoc >=0.3.0",62 "griffe-warnings-deprecated >=1.1.0",63 "markdown-include-variants >=0.0.8",64 "mdx-include >=1.4.1",65 "mkdocs-macros-plugin >=1.5.0",66 "mkdocs-material >=9.7.1",67 "mkdocs-redirects >=1.2.1",68 "mkdocstrings[python] >=0.30.1",69 "pillow >=11.3.0",70 "pyyaml >=5.3.1",📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 71–72why, one step back71]72github-actions = [📌 Update internal dependency limits (#1529)Sebastián Ramírezbefore adoption69d48e0
lines 73–77why, one step back73 "httpx >=0.27.0",74 "pydantic >=2.5.3",75 "pydantic-settings >=2.1.0",76 "pygithub >=2.3.0",77 "smokeshow >=0.5.0",📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 78–79why, one step back78]79tests = [🔧 Upgrade pytest version and config (#1570)Sebastián Ramírezbefore adoption3840899
line 80why, one step back80 "coverage[toml] >=7.13",📌 Update internal dependency limits (#1529)Sebastián Ramírezbefore adoption69d48e0
line 81why, one step back81 "mypy >=1.19.1",⬆ Bump ty from 0.0.24 to 0.0.25 (#1652)dependabot[bot]before adoption2046219
line 82why, one step back82 "ty >=0.0.25",🔧 Upgrade pytest version and config (#1570)Sebastián Ramírezbefore adoption3840899
line 83why, one step back83 "pytest >=9.0.0",👷 Run tests with lower bound uv sync, update minimum dependencies (#1526)Motov Yuriibefore adoption459030e
lines 84–85why, one step back84 "pytest-cov >=4.0.0",85 "pytest-sugar >=0.9.5",📌 Update internal dependency limits (#1529)Sebastián Ramírezbefore adoption69d48e0
line 86why, one step back86 "pytest-xdist >=1.32.0",👷 Run tests with lower bound uv sync, update minimum dependencies (#1526)Motov Yuriibefore adoption459030e
line 87why, one step back87 "rich >=12.3.0",📌 Update internal dependency limits (#1529)Sebastián Ramírezbefore adoption69d48e0
lines 88–89why, one step back88 "ruff >=0.15.0",89 "shellingham >=1.3.0",📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 90–102why, one step back90]9192[tool.pdm]93version = { source = "file", path = "typer/__init__.py" }94distribution = true9596[tool.pdm.build]97source-includes = [98 "tests/",99 "docs_src/",100 "scripts/",101]102🔧 Upgrade pytest version and config (#1570)Sebastián Ramírezbefore adoption3840899
lines 103–104why, one step back103[tool.pytest]104minversion = "9.0"📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 105–108why, one step back105addopts = [106 "--strict-config",107 "--strict-markers",108]🔧 Upgrade pytest version and config (#1570)Sebastián Ramírezbefore adoption3840899
line 109why, one step back109strict_xfail = true📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 110–174why, one step back110filterwarnings = [111 "error",112 # For pytest-xdist113 'ignore::DeprecationWarning:xdist',114]115116[tool.coverage.run]117parallel = true118data_file = "coverage/.coverage"119source = [120 "docs_src",121 "tests",122 "typer"123]124omit = [125 "typer/_typing.py",126]127context = '${CONTEXT}'128relative_files = true129130[tool.coverage.report]131exclude_lines = [132 "pragma: no cover",133 "@overload",134 'if __name__ == "__main__":',135 "if TYPE_CHECKING:",136]137138[tool.mypy]139strict = true140141[[tool.mypy.overrides]]142module = "docs_src.*"143disallow_incomplete_defs = false144disallow_untyped_defs = false145disallow_untyped_calls = false146147[[tool.mypy.overrides]]148module = "shellingham"149ignore_missing_imports = true150151[tool.ruff.lint]152select = [153 "E", # pycodestyle errors154 "W", # pycodestyle warnings155 "F", # pyflakes156 "I", # isort157 "B", # flake8-bugbear158 "C4", # flake8-comprehensions159 "UP", # pyupgrade160 "TID", # flake8-tidy-imports161]162ignore = [163 "E501", # line too long, handled by black164 "B008", # do not perform function calls in argument defaults165 "C901", # too complex166 "W191", # indentation contains tabs167 "TID252", # relative imports okay168]169170[tool.ruff.lint.per-file-ignores]171# "__init__.py" = ["F401"]172# rich_utils is allowed to use rich imports173"typer/rich_utils.py" = ["TID251"]174# This file is more readable without yield from➖ Drop support for Python 3.9 (#1546)Sebastián Ramírezbefore adoption28035df
line 175why, one step back175"docs_src/progressbar/tutorial004_py310.py" = ["UP028", "B007"]📝 Update release notesgithub-actions[bot]before adoptioncb0e472
line 176why, one step back176# Default mutable data structure➖ Drop support for Python 3.9 (#1546)Sebastián Ramírezbefore adoption28035df
lines 177–182why, one step back177"docs_src/options_autocompletion/tutorial006_an_py310.py" = ["B006"]178"docs_src/multiple_values/multiple_options/tutorial002_an_py310.py" = ["B006"]179"docs_src/options_autocompletion/tutorial007_an_py310.py" = ["B006"]180"docs_src/options_autocompletion/tutorial008_an_py310.py" = ["B006"]181"docs_src/options_autocompletion/tutorial009_an_py310.py" = ["B006"]182"docs_src/parameter_types/enum/tutorial003_an_py310.py" = ["B006"]📝 Update release notesgithub-actions[bot]before adoptioncb0e472
line 183why, one step back183# Loop control variable `value` not used within loop body➖ Drop support for Python 3.9 (#1546)Sebastián Ramírezbefore adoption28035df
lines 184–187why, one step back184"docs_src/progressbar/tutorial001_py310.py" = ["B007"]185"docs_src/progressbar/tutorial003_py310.py" = ["B007"]186"docs_src/progressbar/tutorial005_py310.py" = ["B007"]187"docs_src/progressbar/tutorial006_py310.py" = ["B007"]📝 Update release notesgithub-actions[bot]before adoptioncb0e472
line 188why, one step back188# Local variable `delete` is assigned to but never used➖ Drop support for Python 3.9 (#1546)Sebastián Ramírezbefore adoption28035df
line 189why, one step back189"docs_src/prompt/tutorial003_py310.py" = ["F841"]📝 Update release notesgithub-actions[bot]before adoptioncb0e472
lines 190–211why, one step back190# No need to worry about rich imports in docs191"docs_src/*" = ["TID"]192193[tool.ruff.lint.isort]194known-third-party = ["typer", "click"]195# For docs_src/subcommands/tutorial003/196known-first-party = ["reigns", "towns", "lands", "items", "users"]197198[tool.ruff.lint.pyupgrade]199# Preserve types, even if a file imports `from __future__ import annotations`.200keep-runtime-typing = true201202[tool.ruff.lint.flake8-tidy-imports]203# Import rich_utils from within functions (lazy), not at the module level (TID253)204banned-module-level-imports = ["typer.rich_utils"]205206[tool.ruff.lint.flake8-tidy-imports.banned-api]207"rich".msg = "Use 'typer.rich_utils' instead of importing from 'rich' directly."208"shellingham.detect_shell".msg = """\209Use 'typer._completion_shared._get_shell_name' instead of using \210'shellingham.detect_shell' directly.211"""👷 Configure `ty` to exit with error code on warnings (#1657)Sofie Van Landeghembefore adoptionf96a4a1
lines 212–214why, one step back212213[tool.ty.terminal]214error-on-warning = true