Skip to content

Commit a14eca7

Browse files
EliahKaganclaude
andcommitted
build(tox): install documentation dependencies from the doc group
The documentation build dependencies (Sphinx and its extensions) used to be the `doc` extra. 9e54de4 (gitpython-developers#2243) moved them to a PEP 735 `doc` dependency group in `pyproject.toml`, and CI now installs them with `pip install --group doc`, but the tox `html` environment still asked for the `doc` extra. GitPython no longer has that extra, so `tox -e html` failed before building anything: html: failed with extras not found for package GitPython: doc (available: gix, test) Install the `doc` dependency group with `dependency_groups = doc` instead. `extras =` is set to empty, so the environment still installs only GitPython and the documentation dependencies, as it did with `extras = doc`, rather than inheriting `extras = test` from `[testenv]`. `dependency_groups` was added in tox 4.22, so raise the `requires` floor from `tox>=4` to `tox>=4.22`. With an older tox installed, tox then provisions a new enough one rather than ignoring the setting. Run locally with tox 4.67.1, `tox -e html` now installs the group and builds the HTML documentation successfully. Sphinx reports one warning, about the docstring of `git.objects.submodule.util.is_relative_url`. CI's documentation build reports the same single warning. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 3513562 commit a14eca7

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

‎tox.ini‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[tox]
2-
requires = tox>=4
2+
requires = tox>=4.22
33
env_list = py{38,39,310,311,312,313,314,315}, ruff, format, mypy, html, misc
44

55
[testenv]
@@ -51,7 +51,8 @@ ignore_outcome = true
5151
[testenv:html]
5252
description = Build HTML documentation
5353
base_python = py{39,310,311,312,38}
54-
extras = doc
54+
extras =
55+
dependency_groups = doc
5556
allowlist_externals = make
5657
commands =
5758
make BUILDDIR={env_tmp_dir}/doc/build -C doc clean

0 commit comments

Comments
 (0)