Skip to content

Commit 91f6639

Browse files
committed
Merge branch 'fix-tox-415'
2 parents 1116153 + 6e2ace4 commit 91f6639

File tree

2 files changed

+14
-9
lines changed

2 files changed

+14
-9
lines changed

tox.ini

+9-8
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ isolated_build = true
33
envlist =
44
clear-coverage
55
quality
6-
py37-tox{3,4}
7-
py38-tox{3,4}
8-
py39-tox{3,4}
9-
py310-tox{3,4}
6+
py37-tox{3,414,4}
7+
py38-tox{3,414,4}
8+
py39-tox{3,414,4}
9+
py310-tox{3,414,4}
1010
compute-coverage
1111
skip_missing_interpreters = true
1212

@@ -17,6 +17,7 @@ setenv =
1717
deps =
1818
coverage
1919
tox3: tox == 3.*
20+
tox414: tox == 4.*,<4.15
2021
tox4: tox == 4.*
2122
commands =
2223
coverage run --parallel-mode --include=tox_ipdb.py,tests.py --branch -m unittest {posargs:discover}
@@ -30,10 +31,10 @@ commands =
3031

3132
[testenv:compute-coverage]
3233
depends =
33-
py37-tox{3,4}
34-
py38-tox{3,4}
35-
py39-tox{3,4}
36-
py310-tox{3,4}
34+
py37-tox{3,414,4}
35+
py38-tox{3,414,4}
36+
py39-tox{3,414,4}
37+
py310-tox{3,414,4}
3738
# Use single virtualenv for both coverage envs.
3839
envdir = {toxworkdir}/coverage
3940
parallel_show_output = true

tox_ipdb.py

+5-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,11 @@ def tox_add_env_config(env_conf: EnvConfigSet, state: State) -> None:
5959
_LOGGER.debug("tox-ipdb-plugin[%s]: New deps: %s", env_conf.name, new_deps)
6060

6161
override = Override('{}.deps={}'.format(env_conf.name, '\n'.join(new_deps)))
62-
env_conf.loaders[0].overrides[override.key] = override
62+
# API changed in tox 4.15.0
63+
if LooseVersion(tox.__version__) < LooseVersion('4.15.0'):
64+
env_conf.loaders[0].overrides[override.key] = override # type: ignore[assignment]
65+
else:
66+
env_conf.loaders[0].overrides.setdefault(override.key, []).append(override)
6367

6468
# Clear cache
6569
env_conf._defined['deps']._cache = _PLACE_HOLDER # type: ignore[attr-defined] # _cache is not public API

0 commit comments

Comments
 (0)