-
Notifications
You must be signed in to change notification settings - Fork 4
/
pyproject.toml
163 lines (142 loc) · 3.71 KB
/
pyproject.toml
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
[tool.commitizen]
name = "cz_conventional_commits"
version = "0.8.1"
tag_format = "$version"
version_files = ["pyproject.toml:version"]
[tool.ruff]
line-length = 88
target-version = "py39"
[tool.ruff.lint]
ignore = ["E501", "D1", "D415"]
extend-select = [
# Enable entire ruff rule section
"I", # Missing required import (auto-fixable)
"UP", # Pyupgrade
"ASYNC", # subset of flake8-async rules
"TCH", # Rules around TYPE_CHECKING blocks
"FA100",
"G", # flake8-logging-format rules
"LOG", # flake8-logging rules, most of them autofixable
"PT", # flake8-pytest-style rules
"TID25", # flake8-tidy-imports rules
"E", # pycodestyle rules
"W", # pycodestyle rules
]
[tool.ruff.lint.pyupgrade]
# Preserve types, even if a file imports `from __future__ import annotations`.
keep-runtime-typing = true
[tool.ruff.lint.isort]
required-imports = ["from __future__ import annotations"]
combine-as-imports = true
known-first-party = ["tests"]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.mypy]
files = ["bahamut_ani_stat", "tests"]
ignore_missing_imports = true
follow_imports = "silent"
warn_redundant_casts = true
warn_unused_ignores = true
warn_unused_configs = true
plugins = ["sqlalchemy.ext.mypy.plugin"]
[[tool.mypy.overrides]]
module = ["bahamut_ani_stat.*"]
# Ensure full coverage
disallow_untyped_calls = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
disallow_untyped_decorators = true
# Restrict dynamic typing
disallow_any_generics = true
disallow_subclassing_any = true
warn_return_any = true
[[tool.mypy.overrides]]
module = ["tests.*"]
disallow_untyped_defs = false
disallow_untyped_decorators = false
[tool.pytest.ini_options]
minversion = "7.2.0"
testpaths = "tests"
addopts = "--strict-markers"
norecursedirs = [
".*",
"build",
"dist",
"CVS",
"_darcs",
"{arch}",
"*.egg",
"venv",
"env",
"virtualenv",
]
markers = ["slow"]
[tool.coverage]
[tool.coverage.report]
show_missing = true
exclude_lines = [
# Have to re-enable the standard pragma
'pragma: no cover',
# Don't complain about missing debug-only code:
'def __repr__',
'if self\.debug',
# Don't complain if tests don't hit defensive assertion code:
'raise AssertionError',
'raise NotImplementedError',
# Don't complain if non-runnable code isn't run:
'if 0:',
'if __name__ == .__main__.:',
]
omit = ['env/*', 'venv/*', '*/virtualenv/*', '*/virtualenvs/*', '*/tests/*']
[tool.poetry]
name = "bahamut_ani_stat"
version = "0.8.1"
authors = ["Wei Lee <[email protected]>"]
description = "Toolkit for Bahamut ani gamer data"
license = "MIT license"
readme = "docs/README.md"
repository = "https://github.com/Lee-W/bahamut_ani_stat"
[tool.poetry.dependencies]
python = "^3.9"
httpx = "^0.27.0"
beautifulsoup4 = "^4.12.3"
tqdm = "^4.61.1"
dataclasses-json = "^0.5.4"
lxml = "^5.0.0"
click = "^8.0.1"
SQLAlchemy = { extras = ["mypy"], version = "^1.4.0" }
bokeh = "^3.0.0"
pandas = "^2.0.0"
pydantic = "^2.0.0"
pydantic-settings = "^2.4.0"
setuptools = ">=72.1,<76.0"
[tool.poetry.dev-dependencies]
# task management
invoke = "^2.0.0"
# test
pytest = "^8.3.3"
pytest-cov = "^5.0.0"
pytest-mock = "^3.0.0"
pytest-regressions = "^2.5.0"
pytest-httpx = "^0.30.0"
pytest-datadir = "^1.5.0"
pytest-sugar = "^1.0.0"
coverage = { extras = ["toml"], version = "^7.0.0" }
# style
ruff = "^0.6.5"
mypy = "^1.11.2"
# securitykk
bandit = "^1.7.9"
pip-audit = "^2.7.3"
# git
commitizen = "^3.0.0"
pre-commit = "^3.0.0"
# documentation
mkdocs = "^1.6.1"
mkdocs-material = "^9.5.35"
# type hinting
types-PyYAML = "^6.0.12.20240917"
types-setuptools = "^75.1.0"
[build-system]
requires = ["poetry_core>=1.0.0"]
build-backend = "poetry.core.masonry.api"