-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathpyproject.toml
More file actions
184 lines (160 loc) · 5.07 KB
/
pyproject.toml
File metadata and controls
184 lines (160 loc) · 5.07 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
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
[build-system]
requires = ["setuptools>=80", "wheel", "setuptools_scm>=8"]
build-backend = "setuptools.build_meta"
[project]
name = "pyUSPTO"
description = "A Modern Python client for accessing the United States Patent and Trademark Office (USPTO) Open Data Portal (ODP) APIs."
authors = [
{ name = "Andrew Piechocki", email = "apiechocki@dunlapcodding.com" },
]
readme = "README.md"
requires-python = ">=3.10"
license = "MIT"
license-files = ["LICENSE*"]
classifiers = [
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Operating System :: OS Independent",
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"Intended Audience :: Education",
"Intended Audience :: Information Technology",
"Intended Audience :: Legal Industry",
"Intended Audience :: Science/Research",
"Intended Audience :: Other Audience",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: POSIX :: Linux",
"Topic :: Software Development :: Libraries",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Information Analysis",
"Topic :: Education",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Office/Business",
"Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Utilities",
]
keywords = ["uspto", "patent", "odp", "client", "bulk data", "patent data"]
dependencies = [
"requests>=2.32.5",
"typing-extensions>=4.15.0; python_version < '3.11'",
"tzdata>=2026.1",
"urllib3>=2.0.0",
]
dynamic = ["version"]
[project.optional-dependencies]
test = [
"pytest>=9.0.2",
"pytest-cov>=7.0.0",
"pytest-mock>=3.15.1",
"typing_extensions>=4.15.0",
]
docs = [
"sphinx>=9.1.0",
"sphinx-rtd-theme>=3.1.0",
"sphinx-autodoc-typehints>=3.9.5",
"sphinx-copybutton>=0.5.2",
"myst-parser>=5.0.0",
]
lint = ["mypy>=1.19.0", "types-requests>=2.32.4", "ruff>=0.15.0"]
dev = ["pyUSPTO[test]", "pyUSPTO[docs]", "pyUSPTO[lint]"]
[project.urls]
GitHub = "https://github.com/DunlapCoddingPC/pyUSPTO"
homepage = "https://github.com/DunlapCoddingPC/pyUSPTO"
issues = "https://github.com/DunlapCoddingPC/pyUSPTO/issues"
Documentation = "https://pyuspto.readthedocs.io/en/latest/"
releasenotes = "https://github.com/DunlapCoddingPC/pyUSPTO/releases/latest"
[tool.setuptools_scm]
[tool.setuptools]
zip-safe = true
[tool.setuptools.packages.find]
where = ["src"]
[tool.setuptools.package-data]
pyUSPTO = ["py.typed"]
[tool.ruff]
line-length = 88
target-version = "py310"
[tool.ruff.lint]
# Enable pycodestyle (E), Pyflakes (F), pydocstyle (D), isort (I), and pyupgrade (UP)
select = ["E", "F", "W", "D", "I", "UP"]
ignore = [
"D203", # one-blank-line-before-class (conflicts with D211)
"D213", # multi-line-summary-second-line (conflicts with D212)
"E501", # line-too-long (handled by formatter where possible)
]
[tool.ruff.lint.per-file-ignores]
"tests/**" = ["D"] # Ignore all pydocstyle rules in tests
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.lint.isort]
known-first-party = ["pyUSPTO"]
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
line-ending = "auto"
[tool.pytest.ini_options]
testpaths = ["tests"]
pythonpath = ["src"]
[tool.coverage.run]
source = ["src/pyUSPTO"]
omit = ["src/pyUSPTO/_version.py"]
[tool.coverage.report]
exclude_lines = [
# Skip protocol definitions
"class FromDictProtocol\\(Protocol\\):",
"def from_dict\\(cls, data: Dict\\[str, Any\\]\\) -> Any:",
"\\.\\.\\.",
# Skip abstract methods
"@abstractmethod",
# Skip defensive assertion code
"raise NotImplementedError",
# Skip type checking blocks
"if TYPE_CHECKING:",
"pass",
]
[tool.mypy]
mypy_path = "src"
python_version = "3.11"
warn_return_any = true
warn_unused_configs = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
check_untyped_defs = true
no_implicit_optional = true
strict_optional = true
warn_redundant_casts = true
warn_unused_ignores = true
warn_no_return = true
warn_unreachable = true
# Per-module configs
[[tool.mypy.overrides]]
module = "pyUSPTO.*"
disallow_untyped_defs = true
# Less strict for tests - allow untyped test functions
[[tool.mypy.overrides]]
module = "tests.*"
disallow_untyped_defs = false
disallow_incomplete_defs = false
disallow_untyped_decorators = false
check_untyped_defs = false
warn_unused_ignores = false
warn_unreachable = false
# Ignore missing stubs for third-party packages
[[tool.mypy.overrides]]
module = ["pytest.*", "pytest", "requests.*", "urllib3.*"]
ignore_missing_imports = true
[tool.deptry.per_rule_ignores]
DEP002 = [
"tzdata",
"pytest", "pytest-cov", "pytest-mock",
"sphinx", "sphinx-rtd-theme", "sphinx-autodoc-typehints",
"sphinx-copybutton", "myst-parser",
"mypy", "types-requests",
"ruff",
]