-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathpyproject.toml
More file actions
238 lines (211 loc) · 6.66 KB
/
pyproject.toml
File metadata and controls
238 lines (211 loc) · 6.66 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
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
[project]
name = "dbs-annotator"
description = "An application for annotating deep brain stimulation programming sessions."
readme = "README.md"
requires-python = ">=3.12"
authors = [
{ name = "Lucia Poma", email = "lucia.poma@wysscenter.ch" },
{ name = "Matteo Vissani" },
{ name = "Richard Köhler", email = "richard.koehler@wysscenter.ch" },
]
keywords = ["dbs", "annotation", "neuroscience", "deep-brain-stimulation"]
dynamic = ["version"]
classifiers = [
"Intended Audience :: Healthcare Industry",
"Intended Audience :: Science/Research",
"Topic :: Scientific/Engineering :: Medical Science Apps.",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.12",
"License :: OSI Approved :: MIT License",
"Environment :: X11 Applications :: Qt",
"Operating System :: OS Independent",
]
dependencies = [
"certifi>=2024.0.0",
"tzdata>=2026.2",
"pandas>=3.0.3",
"python-docx>=1.1",
"docx2pdf>=0.1.8",
"pydantic>=2.13.4",
"pyside6>=6.11.0",
"matplotlib>=3.10.9",
"packaging>=26.2",
"idna>=3.15",
]
[dependency-groups]
dev = [
"pytest>=8.0.0",
"pytest-qt>=4.4.0",
"pytest-timeout>=2.3.0",
"pytest-cov>=4.1.0",
"ruff>=0.1.0",
"pre-commit>=3.6",
"pre-commit-uv>=4.2.1",
"uv>=0.11.15",
"ty>=0.0.35",
"pandas-stubs>=3.0.0.260204",
"pyside6-stubs>=6.7.3.0",
"towncrier>=24.8.0",
]
build = ["briefcase>=0.4.2"]
docs = [
"sphinx>=9.0.4",
"sphinx-rtd-theme>=3.1.0",
"sphinx-copybutton>=0.5.2",
"myst-parser>=4.0.0",
]
[project.scripts]
dbs-annotator = "dbs_annotator.__main__:main"
[project.urls]
Homepage = "https://github.com/Brain-Modulation-Lab/DBSAnnotator"
Repository = "https://github.com/Brain-Modulation-Lab/DBSAnnotator"
Documentation = "https://dbs-annotator.readthedocs.io/en/latest/"
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.version]
path = "src/dbs_annotator/__init__.py"
[tool.hatch.build.targets.wheel]
packages = ["src/dbs_annotator"]
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
addopts = [
"--verbose",
"--timeout=3",
"--cov=dbs_annotator",
"--cov-report=html",
"--cov-report=term-missing",
]
filterwarnings = ["ignore::DeprecationWarning"]
markers = [
"gui: Qt GUI / widget tests",
"integration: cross-module behavior",
"slow: longer GUI or lazy-loaded wizard flows; skip locally with pytest -m \"not slow\"",
"docs_screenshot: optional screenshot generation for docs artifacts",
]
[tool.coverage.run]
source = ["src"]
omit = ["*/tests/*"]
[tool.coverage.report]
omit = ["*/tests/*"]
[tool.ruff]
line-length = 88
target-version = "py312"
extend-exclude = [".eggs", ".git", ".hatch", ".venv", "build", "dist"]
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
"I", # isort
"N", # pep8-naming
"UP", # pyupgrade
"B", # flake8-bugbear
"C4", # flake8-comprehensions
]
[tool.ruff.lint.per-file-ignores]
"docs/conf.py" = ["E402"]
"src/dbs_annotator/views/wizard_window.py" = ["E501"]
[tool.codespell]
ignore-words-list = "vas"
skip = "uv.lock,.venv,build,dist,htmlcov,docs/_build,*.svg,*.ico,*.png,*.pdf,*.log,*.min.js"
[tool.doc8]
max-line-length = 100
ignore = ["D004"]
ignore-path = ["docs/_build", "docs/_templates"]
[tool.interrogate]
fail-under = 85
ignore-init-module = true
ignore-magic = true
ignore-private = true
ignore-semiprivate = true
ignore-nested-functions = true
exclude = ["tests", "build", "dist", ".venv", "docs/_build"]
verbose = 0
quiet = false
[tool.uv]
exclude-newer = "1 week"
exclude-newer-package = { lxml = false, idna = false }
[tool.towncrier]
package = "dbs_annotator"
package_dir = "src"
directory = "newsfragments"
filename = "CHANGELOG.md"
template = "newsfragments/template.md.jinja"
start_string = "## [Unreleased]"
title_format = "## [{version}] - {project_date}"
# Render each fragment's PR/issue as a Markdown link in CHANGELOG (GitHub + MyST)
issue_format = "[#{issue}](https://github.com/Brain-Modulation-Lab/DBSAnnotator/pull/{issue})"
underlines = ["", "", ""]
# Order matches https://keepachangelog.com/en/1.1.0/ (Types of changes)
[[tool.towncrier.type]]
directory = "added"
name = "Added"
showcontent = true
[[tool.towncrier.type]]
directory = "changed"
name = "Changed"
showcontent = true
[[tool.towncrier.type]]
directory = "deprecated"
name = "Deprecated"
showcontent = true
[[tool.towncrier.type]]
directory = "removed"
name = "Removed"
showcontent = true
[[tool.towncrier.type]]
directory = "fixed"
name = "Fixed"
showcontent = true
[[tool.towncrier.type]]
directory = "security"
name = "Security"
showcontent = true
[tool.briefcase]
project_name = "DBSAnnotator"
bundle = "ch.wysscenter.dbsannotator"
# Briefcase requires a static version here even when [project] uses dynamic version
version = "0.4.0"
license = { file = "LICENSE" }
# Windows per-user install dir is %LOCALAPPDATA%\<author>\<formal_name>; must match
# FS_ORG_NAME in dbs_annotator.config (Qt user data / lab convention).
author = "WyssGeneva"
author_email = "lucia.poma@wysscenter.ch"
url = "https://github.com/Brain-Modulation-Lab/DBSAnnotator"
[tool.briefcase.app.dbs_annotator]
formal_name = "DBSAnnotator"
description = "An application for annotating deep brain stimulation programming sessions."
long_description = """
DBS Annotator is a desktop application used to structure and review
deep brain stimulation programming sessions in a reproducible workflow.
It supports clinicians and researchers by organizing session information,
tracking stimulation settings, and generating standardized exports and reports.
"""
sources = ["src/dbs_annotator", "icons", "styles"]
icon = "icons/logosimple/logosimple"
installer_icon = "icons/logosimple/logosimple"
requirement_installer_args = [
"--index-url",
"https://pypi.org/simple",
"--constraint",
"constraints-briefcase.txt",
"--retries",
"5",
"--timeout",
"60",
"--no-cache-dir",
]
[tool.briefcase.app.dbs_annotator.macOS]
universal_build = false
# PySide6 6.8+ publishes macOS wheels tagged `macosx_13_0_universal2`. The Briefcase
# support-package Python on macOS advertises a lower platform tag by default, so its
# embedded pip refuses all PySide6 versions newer than 6.7.3 with a misleading
# "No matching distribution" error. Setting `min_os_version = "13.0"` tells Briefcase
# (and the bundled interpreter/installer) to target macOS 13+, aligning platform tags
# with the published wheels. If a compatible support package is not available, Briefcase
# will select the closest one and raise the deployment target accordingly.
min_os_version = "13.0"