-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtox.ini
More file actions
151 lines (138 loc) · 3.78 KB
/
Copy pathtox.ini
File metadata and controls
151 lines (138 loc) · 3.78 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
[tox]
requires =
tox>=4.2
env_list =
lint
harness
typecheck
docs
frontier-contract
version-sync
py{314, 313, 312, 311, 310}
min_versions
max_versions
coverage_report
skip_missing_interpreters = true
[testenv]
description = Run pytest tests with {envname}
deps =
.[ci]
jsonschema>=4
set_env =
MPLBACKEND = Agg
commands =
pytest --no-cov {posargs} # Pass positional arguments to pytest (e.g., for specific test files)
[testenv:lint]
description = Run linters and formatters
skip_install = true
deps =
bandit<2.0,>=1.7
ruff<1.0,>=0.9
commands =
ruff check voiage tests --fix --exit-non-zero-on-fix
ruff format voiage tests --check
bandit -r voiage -s B101,B110,B405,B314 -c pyproject.toml
[testenv:harness]
description = Run repository quality and workflow security harness
skip_install = true
deps =
.[ci]
commands =
python scripts/repo_harness.py
pytest tests/test_repo_harness.py --no-cov -q
[testenv:typecheck]
description = Run static type checking with ty
skip_install = true
deps =
matplotlib>=3.4
numpy>=1.20
pandas>=1.3
scikit-learn>=1
seaborn>=0.11
statsmodels>=0.13
ty<1.0,>=0.0.1
typer>=0.9
types-setuptools
xarray>=0.19
commands =
ty check voiage --python-version=3.10 --ignore invalid-argument-type --ignore invalid-assignment --ignore unresolved-attribute --ignore unresolved-import --ignore no-matching-overload --ignore unsupported-operator --ignore call-non-callable --ignore not-iterable --ignore not-subscriptable --ignore invalid-return-type --ignore invalid-method-override --ignore unused-type-ignore-comment --ignore redundant-cast {posargs}
[testenv:docs]
description = Check and build the Astro/Starlight documentation site
skip_install = true
changedir = docs/astro-site
allowlist_externals = pnpm
commands =
pnpm install --frozen-lockfile
pnpm run check
pnpm run build
[testenv:frontier-contract]
commands =
python scripts/validate_frontier_contract.py
base = frontier-contract-base
[testenv:version-sync]
description = Validate canonical version synchronization across package manifests
skip_install = true
deps =
.[ci]
commands =
python scripts/validate_version_sync.py
[testenv:min_versions]
description = Test with minimum dependency versions
base_python = python3.10
deps =
.[ci]
jsonschema>=4
numpy<1.25,>=1.24
pandas<1.6,>=1.5.3
scipy<1.11,>=1.10
commands =
pytest --no-cov {posargs}
[testenv:max_versions]
description = Test with maximum dependency versions
deps =
.[ci]
jsonschema>=4
numpy<3.0,>=2.1
pandas<3.0,>=2.3
scikit-learn<2.0,>=1.8
scipy<1.17,>=1.16.3
commands =
pytest --no-cov {posargs}
[testenv:coverage_report]
description = Generate and check code coverage report
deps =
coverage>=7.0 # pytest-cov uses coverage.py
defusedxml>=0.7
fastapi>=0.115,<1.0
hypothesis>=6
httpx>=0.27,<1.0
jsonschema>=4
pytest>=7
pytest-benchmark>=4
pytest-cov>=3
PyYAML>=6,<7
commands =
pytest tests/ --cov=voiage --cov-config=pyproject.toml --cov-report=term-missing --cov-report=xml --cov-report=html --cov-fail-under=90 # Generate and verify coverage in the same environment as local development
allowlist_externals =
uv
[frontier-contract-base]
description = Validate the frontier VOI registry and family manifests
skip_install = true
[testenv:safety]
description = Run safety check for dependency vulnerabilities
deps =
safety>=2.3
pip-tools>=7.0
allowlist_externals =
rm
commands =
pip-compile --generate-hashes pyproject.toml --output-file=requirements-security.txt
safety check -r requirements-security.txt
rm requirements-security.txt
[gh-actions]
python =
3.10: py310
3.11: py311
3.12: py312
3.13: py313
3.14: py314