-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpyproject.toml
More file actions
131 lines (115 loc) · 3.06 KB
/
pyproject.toml
File metadata and controls
131 lines (115 loc) · 3.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
[project]
name = "modelsdotdev"
dynamic = ["version"]
description = "An offline models.dev database bundle exposed as a typed Python module."
readme = "README.md"
license = "MIT"
license-files = ["LICENSE"]
requires-python = ">=3.12"
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Topic :: Software Development :: Libraries :: Python Modules",
"Typing :: Typed",
]
[build-system]
requires = ["hatchling>=1.28.0", "uv-dynamic-versioning>=0.14.0"]
build-backend = "hatchling.build"
[tool.hatch.version]
source = "uv-dynamic-versioning"
[tool.uv-dynamic-versioning]
fallback-version = "0.0.0"
[tool.hatch.build.targets.sdist]
include = [
"/LICENSE",
"/README.md",
"/hatch_build.py",
"/src",
]
[tool.hatch.build.targets.wheel]
packages = ["src/modelsdotdev"]
[tool.hatch.build.hooks.custom]
path = "hatch_build.py"
[dependency-groups]
dev = [
"hatchling~=1.28.0",
"mypy~=2.1.0",
"poethepoet~=0.37.0",
"pytest~=9.0.3",
"ruff~=0.15.2",
"ty~=0.0.35",
]
[tool.poe.tasks]
generate-db = "python -m modelsdotdev._internal.sync"
[tool.mypy]
python_version = "3.12"
strict = true
warn_return_any = true
warn_unused_configs = true
mypy_path = ["src"]
files = ["src/modelsdotdev", "tests", ".github/scripts"]
explicit_package_bases = true
[[tool.mypy.overrides]]
module = "tests.*"
disable_error_code = ["unused-ignore"]
[tool.ty.environment]
python-version = "3.12"
root = ["./src", "./"]
[tool.ruff]
line-length = 80
indent-width = 4
target-version = "py312"
exclude = [
".github",
".git",
"build",
"dist",
".eggs",
]
[tool.ruff.lint]
preview = true
extend-select = [
"B", # flake8-bugbear
"C4", # flake8-comprehensions
"D", # pydocstyle
"E", # error
"ERA", # flake8-eradicate
"F", # pyflakes
"FBT", # flake8-boolean-trap
"G", # flake8-logging-format
"I", # isort
"N", # pep8-naming
"PGH", # pygrep-hooks
"PIE", # flake8-pie
"PLE", # pylint-error
"PLW", # pylint-warning
"PLC", # pylint-convention
"RUF", # ruff specific
"SIM", # flake8-simplify
"T20", # flake8-print
"TC", # flake8-type-checking
"UP", # pyupgrade
"W", # warning
]
extend-ignore = [
"D203", # incorrect-blank-line-before-class
"D213", # multi-line-summary-second-line
"F541", # f-string-missing-placeholders
"PLW1514", # unspecified-encoding (UTF-8 is Python 3 default)
"PLW2901", # redefined-loop-name (intentional pattern for line processing)
]
[tool.ruff.lint.per-file-ignores]
"tests/**/*.py" = [
"D", # docstrings not required in tests
"PLC2701", # allow private imports in tests
]
[tool.pytest.ini_options]
testpaths = ["tests"]
pythonpath = ["src"]