Skip to content

Commit dae1790

Browse files
EliahKaganclaude
andcommitted
build(tox): skip environments whose Python is not installed
The README says that running `tox` locally "skips any Python versions you don't have installed". That was tox's default until tox 4.56.0 changed the default of `skip_missing_interpreters` to false. Since then, an environment whose Python is not installed fails. `env_list` names `py38` through `py315`, so a contributor who runs `tox` without all eight versions gets a failed run. Set `skip_missing_interpreters = true` in `[tox]`, so those environments are skipped again, as the README describes. tox still reports failure if every environment it was asked to run is skipped. Checked with Python 3.9 installed and 3.10 not, using tox 4.22.0 and 4.67.1. `tox -e py39,py310` ran `py39`, skipped `py310`, and passed. With `--skip-missing-interpreters=false`, which overrides the setting, `py310` failed, and so did the run. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 74c4d4e commit dae1790

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎tox.ini‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
[tox]
22
requires = tox>=4.22
3+
# Skip environments whose Python is not installed.
4+
skip_missing_interpreters = true
35
env_list = py{38,39,310,311,312,313,314,315}, ruff, format, mypy, html, misc
46

57
[testenv]

0 commit comments

Comments
 (0)