Repository navigation
Commit ef3e8a0
build(tox): install the in-tree
Since 8a08afa (gitpython-developers#2179), `smmap` and `gitdb` are developed in this
repository, and CI installs them from there, together with GitPython,
with `pip install ./smmap ./gitdb ".[${EXTRAS}]"`. tox did not follow:
its environments install GitPython's wheel, and pip fetches `gitdb` and
`smmap` from PyPI to satisfy its `gitdb>=4.0.1,<5` requirement. So `tox`
could test GitPython against different `gitdb` and `smmap` code than CI
does, for example after a change to them that has not been released yet.
Add the two directories to `deps` in `[testenv]`, as
`{tox_root}/smmap` and `{tox_root}/gitdb`. tox installs `deps` before
the package's own dependencies, which they then satisfy, so pip keeps
them. Every environment that installs GitPython inherits this. `ruff`,
`format`, and `misc` set their own `deps` and skip installing
GitPython, so they are unaffected.
As with other `deps`, tox does not notice changes inside those
directories, so an existing environment needs `tox -r` to pick up
edits to `smmap` or `gitdb`.
Checked with tox 4.22.0 and 4.67.1. `tox config` shows the two paths
in the `deps` of `py39`, `py313`, `mypy`, `html`, and `gix`, and not
`ruff`. `html` and `py39`, which installs and imports GitPython,
passed, and `tox -e py313 -- --collect-only -q test/test_util.py`
collected the tests. In each of those environments, `smmap` 5.0.3 and
`gitdb` 4.0.12 came from the local directories, per their
`direct_url.json`.
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>smmap and gitdb
1 parent 9c7ba76 commit ef3e8a0
1 file changed
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
10 | 14 | | |
11 | 15 | | |
12 | 16 | | |
| |||
0 commit comments