-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathpyproject.toml
180 lines (159 loc) · 4.8 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
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
[build-system]
# hatchling v1.27 was first version to use default metadata version 2.4, allowing project.license
# and project.license-files fields following PEP-639
requires = ["hatchling>=1.27"]
build-backend = "hatchling.build"
[tool.hatch.build]
exclude = [
"/.*",
"/docs",
"/examples",
"/requirements",
"/tools",
]
[project]
name = "pybaselines"
version = "1.2.0"
authors = [
{name = "Donald Erb", email = "donnie.erb@gmail.com"},
]
description = "A library of algorithms for the baseline correction of experimental data."
readme = "README.rst"
license = "BSD-3-Clause"
license-files = [
"LICENSE.txt",
"LICENSES_bundled.txt"
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"Intended Audience :: Developers",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Chemistry",
"Topic :: Scientific/Engineering :: Information Analysis",
"Topic :: Scientific/Engineering :: Physics",
]
keywords = [
"materials characterization",
"materials science",
"baseline",
"background",
"baseline correction",
"baseline subtraction",
"chemistry",
"spectroscopy",
"raman",
]
requires-python = ">=3.9"
dependencies = [
"numpy>=1.20", # lowest version to allow dtype for np.concatenate
"scipy>=1.6", # lowest version supported for python 3.9
]
[project.urls]
Homepage = "https://github.com/derb12/pybaselines"
Documentation = "https://pybaselines.readthedocs.io"
[project.optional-dependencies]
full = [
"pentapy>=1.1", # 1.1.1 is first version with wheels for python 3.9; don't pin patch versions
"numba>=0.53", # first to allow usage with python 3.9
]
test = [
"pytest>=6.0", # first version to work with pyproject.toml
"ruff",
]
docs = [
"sphinx",
"sphinx-copybutton",
"sphinx-gallery>=0.16", # first version allowing strings to specify gallery sorting
"sphinx-rtd-theme",
"matplotlib",
"numpydoc",
]
release = [
"build",
"bump-my-version",
"twine",
]
dev = ["pybaselines[full, docs, test, release]"]
[tool.pytest.ini_options]
addopts = "--strict-markers"
markers = [
"threaded_test: mark a test as using threading and only run on free-threaded CPython by default",
]
[tool.isort]
skip_glob = ["docs/*", "*__init__.py"]
force_sort_within_sections = true
line_length = 100
lines_after_imports = 2
multi_line_output = 5
src_paths = ["pybaselines", "tests"]
# example_helpers are locally used in doc examples
known_local_folder = ["example_helpers"]
[tool.ruff]
exclude = ["docs/*"]
line-length = 100
fix = false
output-format = "full"
[tool.ruff.lint]
preview = true # for using experimental rules
select = [
"B", # flake8-bugbear
"D", # pydocstyle
"E", # pycodestyle errors
"F", # pyflakes
#"I", # isort
"W", # pycodestyle warnings
"C4", # flake8-comprehensions
"NPY", # numpy specific
]
ignore = [
"D401", # D401 first line should be in imperative mood; try rephrasing
"E731", # E731 do not assign a lambda expression, use a def
]
task-tags = ["TODO"]
[tool.ruff.lint.pycodestyle]
ignore-overlong-task-comments = true
[tool.ruff.lint.pydocstyle]
convention = "numpy"
[tool.ruff.lint.per-file-ignores]
"__init__.py" = [
"F401", # F401: module imported but unused
"D205", # D205: 1 blank line required between summary line and description
]
"examples/*" = [
"B007", # B007: Loop control variable `name` not used within loop body; want to be explicit in examples
"D205", # D205: 1 blank line required between summary line and description
"D400", # D400: first line should end with a period
"E501", # E501: line too long; reference links can be very long so ignore the limit
]
"tests/*" = [
"F841", # F841: Local variable 'name' is assigned to but never used; want to be explicit within tests
]
[tool.bumpversion]
current_version = "1.2.0"
commit = false
tag = false
message = "Bump version: {current_version} -> {new_version}"
[[tool.bumpversion.files]]
filename = "pyproject.toml"
search = "version = \"{current_version}\""
replace = "version = \"{new_version}\""
[[tool.bumpversion.files]]
filename = "pybaselines/__init__.py"
search = "__version__ = '{current_version}'"
replace = "__version__ = '{new_version}'"
[[tool.bumpversion.files]]
filename = "docs/conf.py"
search = "version = '{current_version}'"
replace = "version = '{new_version}'"
[[tool.bumpversion.files]]
filename = "CITATION.cff"
search = "version: {current_version}"
replace = "version: {new_version}"