-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpyproject.toml
More file actions
189 lines (173 loc) · 4.91 KB
/
Copy pathpyproject.toml
File metadata and controls
189 lines (173 loc) · 4.91 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
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "pylinkage"
version = "1.2.2"
authors = [
{name = "Hugo Farajallah", email = "contact@hugofara.net"},
]
description = " Create and optimize kinematic planar linkages in Python "
readme = "README.md"
requires-python = ">=3.10"
keywords = [
"linkage", "mechanism", "optimization",
"particle swarm optimization"
]
license = {text = "MIT License"}
classifiers = [
"Development Status :: 5 - Production/Stable",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Topic :: Scientific/Engineering",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Environment :: Console",
"Intended Audience :: Science/Research",
"Intended Audience :: End Users/Desktop",
"Operating System :: OS Independent",
]
dependencies = [
"numpy>=1.20.2",
"tqdm>=4.40.0",
"typing_extensions>=4.0.0; python_version < '3.11'",
]
[project.optional-dependencies]
numba = ["numba>=0.60.0"]
scipy = ["scipy>=1.10.0"]
symbolic = ["sympy>=1.12"]
pso = [] # PSO is now built-in (pure numpy), kept for backwards compatibility
viz = ["matplotlib>=3.3.4"]
plotly = ["plotly>=6.5.0", "ipywidgets>=8.0.0", "anywidget>=0.9.0"]
svg = ["drawsvg>=2.4.0"]
full = [
"numba>=0.60.0",
"scipy>=1.10.0",
"sympy>=1.12",
"matplotlib>=3.3.4",
"plotly>=6.5.0",
"ipywidgets>=8.0.0",
"anywidget>=0.9.0",
"drawsvg>=2.4.0",
"pymoo>=0.6.0",
]
dev = [
"pytest>=7.0.0",
"pytest-cov>=4.0.0",
"mypy>=1.0.0",
"ruff>=0.4.0",
"hypothesis>=6.0.0",
"ipykernel>=6.0.0",
]
docs = [
"sphinx>=7.4.2",
"sphinx-rtd-theme>=2.0.0",
"myst-parser>=3.0.1",
]
cad = [
"ezdxf>=1.0.0",
"build123d>=0.7.0",
]
analysis = [
"pandas>=2.0.0",
]
moo = [
"pymoo>=0.6.0",
]
[project.urls]
Homepage = "https://pylinkage.readthedocs.io/en/latest/"
Documentation = "https://pylinkage.readthedocs.io/en/latest/"
Repository = "https://github.com/HugoFara/pylinkage"
Changelog = "https://github.com/hugofara/pylinkage/blob/main/CHANGELOG.md"
[tool.hatch.build.targets.wheel]
packages = ["src/pylinkage"]
[tool.pytest.ini_options]
testpaths = ["tests"]
# tests/docs executes the example scripts and tutorial pages: minutes, and
# every optional backend. Select them explicitly with `-m docs`.
addopts = "-v -m 'not docs'"
markers = ["docs: executes the documentation's code (slow, needs all extras)"]
[tool.mypy]
python_version = "3.10"
strict = true
warn_unused_ignores = true
ignore_missing_imports = true
[tool.ruff]
target-version = "py310"
line-length = 100
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
"I", # isort
"UP", # pyupgrade
"B", # flake8-bugbear
"SIM", # flake8-simplify
]
[tool.ruff.lint.isort]
known-first-party = ["pylinkage"]
[dependency-groups]
dev = [
"numba>=0.60.0",
"scipy>=1.10.0",
"sympy>=1.12",
"matplotlib>=3.3.4",
"plotly>=6.5.0",
"drawsvg>=2.4.0",
"pytest>=7.0.0",
"pytest-cov>=4.0.0",
"mypy>=1.0.0",
"ruff>=0.4.0",
"hypothesis>=6.0.0",
"sphinx>=7.4.2",
"sphinx-rtd-theme>=2.0.0",
"myst-parser>=3.0.1",
"bump-my-version>=1.2.5",
"taskipy>=1.12.0",
"nbconvert>=7.17.1",
"ipykernel>=7.2.0",
"ipywidgets>=8.1.8",
"anywidget>=0.10.0",
]
[tool.taskipy.tasks]
docs = "sphinx-build -b html docs/source docs/"
docs-clean = "rm -rf docs/*.html docs/*.js docs/_* docs/objects.inv"
test = "pytest"
test-cov = "pytest --cov=pylinkage --cov-report=html"
lint = "ruff check ."
lint-fix = "ruff check . --fix"
format = "ruff format ."
typecheck = "mypy src/pylinkage"
[tool.bumpversion]
current_version = "1.2.2"
commit = true
tag = true
tag_name = "v{new_version}"
tag_message = "Release v{new_version}"
message = "chore: bump version {current_version} → {new_version}"
[[tool.bumpversion.files]]
filename = "pyproject.toml"
search = 'version = "{current_version}"'
replace = 'version = "{new_version}"'
[[tool.bumpversion.files]]
filename = "src/pylinkage/__init__.py"
search = '__version__ = "{current_version}"'
replace = '__version__ = "{new_version}"'
# CITATION.cff carries the release version and date. Both were edited by hand
# before; the DOI below it is the Zenodo concept DOI, which never changes.
# The search is anchored to the line start so that it does not also match the
# `cff-version:` line, which is the CFF format version, not ours.
[[tool.bumpversion.files]]
filename = "CITATION.cff"
regex = true
search = "^version: {current_version}"
replace = "version: {new_version}"
[[tool.bumpversion.files]]
filename = "CITATION.cff"
regex = true
search = 'date-released: "[0-9-]+"'
replace = 'date-released: "{now:%Y-%m-%d}"'