Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
218 lines (198 loc) · 5.36 KB
/
Copy pathpyproject.toml
File metadata and controls
218 lines (198 loc) · 5.36 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
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
[project]
name = "qtframelesskit"
version = "0.2.0"
description = "Modern, cross-Qt frameless window framework for Windows in pure Python."
readme = "README.md"
requires-python = ">=3.10"
license = { text = "MIT" }
authors = [{ name = "BugCodeX" }]
maintainers = [{ name = "BugCodeX", email = "busine015@gmail.com" }]
keywords = [
"acrylic",
"dwm",
"frameless",
"frameless-window",
"mica",
"pyqt5",
"pyqt6",
"pyside6",
"qt",
"snap-layouts",
"titlebar",
"win32",
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Environment :: Win32 (MS Windows)",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: Microsoft :: Windows",
"Operating System :: Microsoft :: Windows :: Windows 10",
"Operating System :: Microsoft :: Windows :: Windows 11",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Desktop Environment :: Window Managers",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Software Development :: User Interfaces",
]
dependencies = [
"pywin32>=312; platform_system=='Windows'",
"qtpy>=2.0.0",
]
[project.urls]
Documentation = "https://qtframelesskit.readthedocs.io/"
Homepage = "https://github.com/BugCodeX/qtframelesskit"
Issues = "https://github.com/BugCodeX/qtframelesskit/issues"
Repository = "https://github.com/BugCodeX/qtframelesskit"
[project.optional-dependencies]
docs = [
"griffe>=1.0.0",
"mkdocs>=1.6.0",
"mkdocs-material>=9.5.0",
"mkdocstrings[python]>=0.26.0",
]
pyqt6 = [
"PyQt6>=6.11.0",
]
pyside6 = [
"PySide6>=6.11.2",
]
test = [
"pytest>=9.0.3",
"pytest-cov>=7.1.0",
"pytest-mock>=3.14.0",
"pytest-qt>=4.2.0",
]
[dependency-groups]
dev = [
"pillow>=10.0.0",
"pre-commit>=4.0.1",
"pyright>=1.1.414",
"pyside6>=6.11.2",
"pytest>=9.0.3",
"pytest-cov>=7.1.0",
"pytest-mock>=3.14.0",
"pytest-qt>=4.2.0",
"ruff>=0.16.8",
]
# ============================================================
# build-system
# ============================================================
[build-system]
requires = ["setuptools>=61.0"]
build-backend = "setuptools.build_meta"
# ============================================================
# coverage
# ============================================================
[tool.coverage.run]
source = ["qtframelesskit"]
omit = [
"examples/*",
"tests/*",
]
# ============================================================
# pyright — type checker
# ============================================================
[tool.pyright]
include = [
"src/qtframelesskit",
"tests",
]
pythonVersion = "3.11"
extraPaths = [
"src/qtframelesskit",
".",
]
typeCheckingMode = "basic"
reportAttributeAccessIssue = false
reportArgumentType = false
reportMissingTypeArgument = false
reportUnknownMemberType = false
reportMatchNotExhaustive = false
reportPrivateImportUsage = false
reportOptionalMemberAccess = false
reportGeneralTypeIssues = false
executionEnvironments = [
{ root = "tests", reportPrivateUsage = false, reportMissingTypeStubs = false },
{ root = "examples", reportMissingTypeStubs = false },
]
# ============================================================
# pytest
# ============================================================
[tool.pytest.ini_options]
addopts = [
"-ra",
"--strict-markers",
"--strict-config",
"--import-mode=importlib",
]
norecursedirs = ["examples", "build", "dist", "htmlcov", ".git"]
python_files = ["test_*.py"]
pythonpath = ["src"]
testpaths = ["tests"]
# ============================================================
# ruff — linter and formatter
# ============================================================
[tool.ruff]
target-version = "py310"
line-length = 100
include = [
"src/**/*.py",
"examples/**/*.py",
"tests/**/*.py",
"scripts/**/*.py",
]
[tool.ruff.lint]
select = [
"D", # pydocstyle
"F", # Pyflakes
"E", # pycodestyle errors
"W", # pycodestyle warnings
"I", # isort
"UP", # pyupgrade
"B", # flake8-bugbear
"SIM", # flake8-simplify
"C4", # flake8-comprehensions
]
ignore = [
"ANN401", # Allow explicit Any.
"E402", # import not at top of file
"D100", # missing module docstring
"E501", # line too long
"D104", # missing public package docstring
"D107", # Skip docstring for __init__.
"D202", # no blank lines after docstring
"F403", # star imports
"SIM102", # nested ifs (sometimes clearer)
"COM812", # trailing comma (conflicts with formatter)
"ISC001", # implicit string concat (conflicts with formatter)
"TD002", # Skip author in TODO.
"TD003", # Skip issue link in TODO.
]
[tool.ruff.lint.pydocstyle]
convention = "numpy"
[tool.ruff.lint.per-file-ignores]
"packages/*/tests/**" = [
"D100", # missing module docstring
"D101", # missing class docstring
"D102", # missing method docstring
"D103", # missing function docstring
]
"examples/**" = [
"D100", # missing module docstring
"D101", # missing class docstring
"D102", # missing method docstring
"D103", # missing function docstring
]
[tool.ruff.format]
quote-style = "double"
indent-style = "space"
skip-magic-trailing-comma = false
docstring-code-format = true
[tool.setuptools.package-data]
qtframelesskit = ["py.typed"]
[tool.setuptools.packages.find]
where = ["src"]