-
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathpyproject.toml
More file actions
195 lines (173 loc) · 4.84 KB
/
pyproject.toml
File metadata and controls
195 lines (173 loc) · 4.84 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
185
186
187
188
189
190
191
192
193
194
195
[project]
name = "kumiko"
version = "1.0.0"
description = "A multipurpose Discord bot built with freedom and choice in mind"
readme = "README.md"
license = {file = "LICENSE"}
requires-python = ">=3.12,<4.0"
dependencies = [
"async-lru~=2.2.0",
"asyncpg~=0.31.0",
"discord-ext-menus",
"discord-py[speed,voice]~=2.6.4",
"jishaku~=2.6.3",
"msgspec~=0.20.0",
"prometheus-async~=25.1.0",
"prometheus-client~=0.24.0",
"psutil~=7.2.1",
"pygit2~=1.19.0",
"python-dateutil~=2.9.0.post0",
"pyyaml~=6.0.3",
"typing-extensions~=4.15.0 ; python_full_version < '3.11'",
"uvloop~=0.22.1 ; sys_platform != 'win32'",
"watchfiles~=1.1.1",
"winloop~=0.5.0 ; sys_platform == 'win32'",
"zstandard~=0.25.0",
]
[tool.uv.sources]
discord-ext-menus = { git = "https://github.com/Rapptz/discord-ext-menus", rev = "8686b5d1bbc1d3c862292eb436ab630d6e9c9b53" }
[dependency-groups]
dev = [
"towncrier~=25.8.0",
{ include-group = "lint" },
{ include-group = "docs" }
]
lint = [
"pyright[nodejs]~=1.1.407",
"ruff~=0.15.0",
]
docs = [
"furo~=2025.12.19",
"sphinx~=9.1.0",
"sphinx-autobuild~=2025.8.25",
"sphinx-copybutton~=0.5.2",
"sphinx-design~=0.7.0",
"sphinxext-opengraph[social-cards]~=0.13.0",
]
[tool.towncrier]
directory = "changes"
filename = "changelog.md"
start_string = "<!-- towncrier release notes start -->"
underlines = ["", "", ""]
title_format = "## Kumiko [{version}](https://github.com/No767/Kumiko/tree/{version}) - {project_date}"
issue_format = "#{issue}"
package = "src.cogs"
[[tool.towncrier.section]]
path = ""
[[tool.towncrier.type]]
directory = "bugfix"
name = "Bug fixes"
showcontent = true
[[tool.towncrier.type]]
directory = "feature"
name = "Features"
showcontent = true
[[tool.towncrier.type]]
directory = "deprecation"
name = "Deprecations (removal in next major release)"
showcontent = true
[[tool.towncrier.type]]
directory = "breaking"
name = "Removals and backward incompatible breaking changes"
showcontent = true
[[tool.towncrier.type]]
directory = "doc"
name = "Improved documentation"
showcontent = true
[[tool.towncrier.type]]
directory = "misc"
name = "Miscellaneous internal changes"
showcontent = true
[tool.pyright]
include = [
"src"
]
exclude = [
"**/node_modules",
"**/.*",
"**/__pycache__",
".venv",
"docs"
]
reportMissingImports = "error"
typeCheckingMode = "standard"
reportUnnecessaryTypeIgnoreComment = "warning"
reportFunctionMemberAccess = "none"
reportCallIssue = "none"
reportArgumentType = "none"
[tool.ruff]
line-length = 88
extend-include = [
"src"
]
extend-exclude = [
"**/__pycache__",
".venv",
"docs"
]
[tool.ruff.lint]
ignore = [
"ANN202", # It's fine sometimes
"ANN401", # Any is the correct type in some cases
"B903", # We don't need to use dataclasses for everything
"B904", # Straight up wrong
"D1", # Too lazy
"D415", # I'm not being formal
"E501", # Ruff formats it, so ignore
"EM101", # Incorrect
"FBT003", # Straight up wrong...
"INP001", # I would prefer not to
"PLR0912", # too many branches
"PLR0913", # number of function arguments
"PLR0915", # too many statements.... in an async entrypoint handling graceful shutdown...
"PLR0917", # too many positional arguments
"PLR2004", # Magic numbers,
"PGH003", # I'm too lazy
"UP007", # Does not account for union unpacking and I prefer this style
"UP045", # No, I prefer this
"TRY003", # Goes against the standard
"RUF029", # async in interface is fine
"S311", # We all know...
"SIM105", # I would prefer not to in most cases
# These are recommended by Ruff if the formatter is to be used: https://docs.astral.sh/ruff/formatter/#conflicting-lint-rules
"W191",
"E111",
"E114",
"E117",
"D206",
"D300",
"Q000",
"Q001",
"Q002",
"Q003",
"COM812",
"COM819",
"ISC001",
"ISC002"
]
# Pulled from https://github.com/mikeshardmind/async-utils/blob/main/pyproject.toml#L149
select = [
"A", "ANN", "ASYNC", "B", "BLE", "C4", "COM", "D", "DTZ", "E",
"EM", "ERA", "F", "FA", "FBT", "FURB", "G", "I", "ICN", "INP", "ISC", "LOG",
"PD", "PERF", "PGH", "PIE", "PLC", "PLE", "PLR", "PLW", "PTH", "PYI",
"Q", "Q003", "RET", "RSE", "RUF", "S", "SIM", "SLOT", "T20", "TC", "TID",
"TRY", "UP", "W", "YTT"
]
fixable = ["ALL"]
unfixable = ["E501"]
[tool.ruff.lint.isort]
combine-as-imports = true
force-wrap-aliases = true
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.ruff.lint.pyupgrade]
keep-runtime-typing = true
[tool.ruff.format]
docstring-code-format = true
[tool.pytest.ini_options]
minversion = "9.0"
addopts = "-ra"
testpaths = [
"tests"
]
asyncio_default_fixture_loop_scope = "function"