Skip to content

Commit 484374c

Browse files
committed
tox: fix errors with tox 4
commands[0]> sh -ec 'python3 -m isort $(git ls-files "*.py")' failed with sh is not allowed, use allowlist_externals to allow it install_deps> tox-install.sh .tox black flake8 isort pylint lint: failed with tox-install.sh (resolves to .../tox-install.sh) is not allowed, use allowlist_externals to allow it Signed-off-by: Robin Jarry <robin@jarry.cc>
1 parent 0be2a57 commit 484374c

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

tox.ini

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,16 @@ basepython = python3
1111
description = Compile extension and run tests against {envname}.
1212
changedir = tests/
1313
install_command = {toxinidir}/tox-install.sh {envdir} {opts} {packages}
14+
allowlist_externals =
15+
{toxinidir}/tox-install.sh
1416
commands = python -Wd -m unittest discover -c
1517

1618
[testenv:coverage]
1719
changedir = .
1820
deps = coverage
1921
install_command = {toxinidir}/tox-install.sh {envdir} {opts} {packages}
22+
allowlist_externals =
23+
{toxinidir}/tox-install.sh
2024
commands =
2125
python -Wd -m coverage run -m unittest discover -c tests/
2226
python -m coverage report
@@ -32,7 +36,7 @@ deps =
3236
isort
3337
skip_install = true
3438
install_command = python3 -m pip install {opts} {packages}
35-
whitelist_externals =
39+
allowlist_externals =
3640
/bin/sh
3741
/usr/bin/sh
3842
commands =
@@ -48,9 +52,10 @@ deps =
4852
flake8
4953
isort
5054
pylint
51-
whitelist_externals =
55+
allowlist_externals =
5256
/bin/sh
5357
/usr/bin/sh
58+
{toxinidir}/tox-install.sh
5459
commands =
5560
sh -ec 'python3 -m black -t py36 --diff --check $(git ls-files "*.py")'
5661
sh -ec 'python3 -m flake8 $(git ls-files "*.py")'

0 commit comments

Comments
 (0)