Skip to content

tox tests fail with virtualenv 20.31 #3531

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
hroncok opened this issue May 12, 2025 · 1 comment · Fixed by #3528
Closed

tox tests fail with virtualenv 20.31 #3531

hroncok opened this issue May 12, 2025 · 1 comment · Fixed by #3528

Comments

@hroncok
Copy link
Contributor

hroncok commented May 12, 2025

Issue

After the recent changes wrt wheel handling in virtualenv 20.31, tox tests started to fail:

=================================== FAILURES ===================================
_________________________ test_plugin_hooks_and_order __________________________
[gw0] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f791428c400>
mocker = <pytest_mock.plugin.MockerFixture object at 0x7f7914302a50>

    def test_plugin_hooks_and_order(tox_project: ToxProjectCreator, mocker: MockerFixture) -> None:
        @impl
        def tox_register_tox_env(register: ToxEnvRegister) -> None:
            assert isinstance(register, ToxEnvRegister)
            logging.warning("tox_register_tox_env")
    
        @impl
        def tox_add_option(parser: ToxParser) -> None:
            assert isinstance(parser, ToxParser)
            logging.warning("tox_add_option")
    
        @impl
        def tox_add_core_config(core_conf: CoreConfigSet, state: State) -> None:
            assert isinstance(core_conf, CoreConfigSet)
            assert isinstance(state, State)
            logging.warning("tox_add_core_config")
    
        @impl
        def tox_add_env_config(env_conf: EnvConfigSet, state: State) -> None:
            assert isinstance(env_conf, EnvConfigSet)
            assert isinstance(state, State)
            logging.warning("tox_add_env_config")
    
        @impl
        def tox_before_run_commands(tox_env: ToxEnv) -> None:
            assert isinstance(tox_env, ToxEnv)
            logging.warning("tox_before_run_commands")
    
        @impl
        def tox_on_install(tox_env: ToxEnv, arguments: Any, section: str, of_type: str) -> None:
            assert isinstance(tox_env, ToxEnv)
            assert arguments is not None
            assert isinstance(section, str)
            assert isinstance(of_type, str)
            logging.warning("tox_on_install %s %s", section, of_type)
    
        @impl
        def tox_after_run_commands(tox_env: ToxEnv, exit_code: int, outcomes: list[Outcome]) -> None:
            assert isinstance(tox_env, ToxEnv)
            assert exit_code == 0
            assert isinstance(outcomes, list)
            assert all(isinstance(i, Outcome) for i in outcomes)
            logging.warning("tox_after_run_commands")
    
        @impl
        def tox_env_teardown(tox_env: ToxEnv) -> None:
            assert isinstance(tox_env, ToxEnv)
            logging.warning("teardown")
    
        plugins = tuple(v for v in locals().values() if callable(v) and hasattr(v, "tox_impl"))
        assert len(plugins) == 8
        register_inline_plugin(mocker, *plugins)
    
        tox_ini = """
            [tox]
            env_list=a,b
            [testenv]
            package=skip
            commands=python -c 'print(1)'
            env_list=a,b
        """
        project = tox_project({"tox.ini": tox_ini})
        result = project.run("r", "-e", "a,b")
        result.assert_success()
        cmd = "print(1)" if sys.platform == "win32" else "'print(1)'"
        expected = [
            "ROOT: tox_register_tox_env",
            "ROOT: tox_add_option",
            "ROOT: tox_add_core_config",
            "a: tox_add_env_config",
            "b: tox_add_env_config",
            "a: tox_on_install PythonRun deps",
            "a: tox_before_run_commands",
            f"a: commands[0]> python -c {cmd}",
            mocker.ANY,  # output a
            "a: tox_after_run_commands",
            "a: teardown",
            mocker.ANY,  # report finished A
            "b: tox_on_install PythonRun deps",
            "b: tox_before_run_commands",
            f"b: commands[0]> python -c {cmd}",
            mocker.ANY,  # output b
            "b: tox_after_run_commands",
            "b: teardown",
            mocker.ANY,  # report a
            mocker.ANY,  # report b
            mocker.ANY,  # overall report
        ]
>       assert result.out.splitlines() == expected, result.out
E       AssertionError: ROOT: tox_register_tox_env
E         ROOT: tox_add_option
E         ROOT: tox_add_core_config
E         a: tox_add_env_config
E         b: tox_add_env_config
E         a: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E         a: tox_on_install PythonRun deps
E         a: tox_before_run_commands
E         a: commands[0]> python -c 'print(1)'
E         1
E         a: tox_after_run_commands
E         a: teardown
E         a: OK ✔ in 5.08 seconds
E         b: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E         b: tox_on_install PythonRun deps
E         b: tox_before_run_commands
E         b: commands[0]> python -c 'print(1)'
E         1
E         b: tox_after_run_commands
E         b: teardown
E           a: OK (5.08=setup[5.00]+cmd[0.08] seconds)
E           b: OK (0.12=setup[0.04]+cmd[0.07] seconds)
E           congratulations :) (5.24 seconds)
E         
E       assert ['ROOT: tox_r...ualenv.', ...] == ['ROOT: tox_r...un deps', ...]
E         
E         At index 5 diff: 'a: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.' != 'a: tox_on_install PythonRun deps'
E         Left contains 2 more items, first extra item: '  b: OK (0.12=setup[0.04]+cmd[0.07] seconds)'
E         Use -v to get more diff

cmd        = "'print(1)'"
expected   = ['ROOT: tox_register_tox_env', 'ROOT: tox_add_option', 'ROOT: tox_add_core_config', 'a: tox_add_env_config', 'b: tox_add_env_config', 'a: tox_on_install PythonRun deps', ...]
mocker     = <pytest_mock.plugin.MockerFixture object at 0x7f7914302a50>
plugins    = (<function test_plugin_hooks_and_order.<locals>.tox_register_tox_env at 0x7f79141fd800>, <function test_plugin_hooks_a...run_commands at 0x7f791428ede0>, <function test_plugin_hooks_and_order.<locals>.tox_on_install at 0x7f791428ee80>, ...)
project    = ToxProject(path=/tmp/pytest-of-churchyard/pytest-20/popen-gw0/test_plugin_hooks_and_order0/p) at 140158006470576
result     = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox r -e a,b
cwd: /tmp/pytest-of-churchyar... (5.08=setup[5.00]+cmd[0.08] seconds)
  b: OK (0.12=setup[0.04]+cmd[0.07] seconds)
  congratulations :) (5.24 seconds)

tox_add_core_config = <function test_plugin_hooks_and_order.<locals>.tox_add_core_config at 0x7f791428eac0>
tox_add_env_config = <function test_plugin_hooks_and_order.<locals>.tox_add_env_config at 0x7f791428eb60>
tox_add_option = <function test_plugin_hooks_and_order.<locals>.tox_add_option at 0x7f79141fd6c0>
tox_after_run_commands = <function test_plugin_hooks_and_order.<locals>.tox_after_run_commands at 0x7f791428ef20>
tox_before_run_commands = <function test_plugin_hooks_and_order.<locals>.tox_before_run_commands at 0x7f791428ede0>
tox_env_teardown = <function test_plugin_hooks_and_order.<locals>.tox_env_teardown at 0x7f791428efc0>
tox_ini    = "\n        [tox]\n        env_list=a,b\n        [testenv]\n        package=skip\n        commands=python -c 'print(1)'\n        env_list=a,b\n    "
tox_on_install = <function test_plugin_hooks_and_order.<locals>.tox_on_install at 0x7f791428ee80>
tox_project = <function init_fixture.<locals>._init at 0x7f791428c400>
tox_register_tox_env = <function test_plugin_hooks_and_order.<locals>.tox_register_tox_env at 0x7f79141fd800>

tests/plugin/test_plugin.py:115: AssertionError
_______________________ test_devenv_fail_multiple_target _______________________
[gw1] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f54bc8f9620>

    def test_devenv_fail_multiple_target(tox_project: ToxProjectCreator) -> None:
        outcome = tox_project({"tox.ini": "[tox]\nenv_list=a,b"}).run("d", "-e", "a,b")
        outcome.assert_failed()
        msg = "ROOT: HandledError| exactly one target environment allowed in devenv mode but found a, b\n"
>       outcome.assert_out_err(msg, "")

msg        = 'ROOT: HandledError| exactly one target environment allowed in devenv mode but found a, b\n'
outcome    = code: -2
cmd: .../tox/.tox/3.13/bin/python3 -m tox d -e a,b
cwd: /tmp/pytest-of-churchya...longer bundled in virtualenv.
ROOT: HandledError| exactly one target environment allowed in devenv mode but found a, b

tox_project = <function init_fixture.<locals>._init at 0x7f54bc8f9620>

tests/session/cmd/test_devenv.py:15: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = code: -2
cmd: .../tox/.tox/3.13/bin/python3 -m tox d -e a,b
cwd: /tmp/pytest-of-churchya...longer bundled in virtualenv.
ROOT: HandledError| exactly one target environment allowed in devenv mode but found a, b

out = 'ROOT: HandledError| exactly one target environment allowed in devenv mode but found a, b\n'
err = ''

    def assert_out_err(self, out: str, err: str, *, dedent: bool = True, regex: bool = False) -> None:
        if dedent:
            out = textwrap.dedent(out).lstrip()
        if regex:
            self.matches(out, self.out, re.MULTILINE | re.DOTALL)
        else:
>           assert self.out == out  # noqa: S101
E           AssertionError: assert '.pkg: The --... found a, b\n' == 'ROOT: Handle... found a, b\n'
E             
E             + .pkg: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E             + .pkg: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E               ROOT: HandledError| exactly one target environment allowed in devenv mode but found a, b

dedent     = True
err        = ''
out        = 'ROOT: HandledError| exactly one target environment allowed in devenv mode but found a, b\n'
regex      = False
self       = code: -2
cmd: .../tox/.tox/3.13/bin/python3 -m tox d -e a,b
cwd: /tmp/pytest-of-churchya...longer bundled in virtualenv.
ROOT: HandledError| exactly one target environment allowed in devenv mode but found a, b


.tox/3.13/lib64/python3.13/site-packages/tox/pytest.py:386: AssertionError
____________________ test_show_config_py_ver_impl_constants ____________________
[gw0] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f790fe6b920>

    def test_show_config_py_ver_impl_constants(tox_project: ToxProjectCreator) -> None:
        tox_ini = "[testenv]\npackage=skip\ndeps= {py_impl}{py_dot_ver}"
        outcome = tox_project({"tox.ini": tox_ini}).run("c", "-e", "py", "-k", "py_dot_ver", "py_impl", "deps")
        outcome.assert_success()
        py_ver = ".".join(str(i) for i in sys.version_info[0:2])
        impl = sys.implementation.name
>       assert outcome.out == f"[testenv:py]\npy_dot_ver = {py_ver}\npy_impl = {impl}\ndeps = {impl}{py_ver}\n"
E       AssertionError: assert '[testenv:py]...cpython3.13\n' == '[testenv:py]...cpython3.13\n'
E         
E           [testenv:py]
E         + ROOT: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E           py_dot_ver = 3.13
E           py_impl = cpython
E           deps = cpython3.13

impl       = 'cpython'
outcome    = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox c -e py -k py_dot_ver py_impl deps
cwd...t for Python > 3.8 as wheel is no longer bundled in virtualenv.
py_dot_ver = 3.13
py_impl = cpython
deps = cpython3.13

py_ver     = '3.13'
tox_ini    = '[testenv]\npackage=skip\ndeps= {py_impl}{py_dot_ver}'
tox_project = <function init_fixture.<locals>._init at 0x7f790fe6b920>

tests/session/cmd/test_show_config.py:85: AssertionError
__________________________ test_show_config_cli_flag ___________________________
[gw8] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f08d9d93560>

    def test_show_config_cli_flag(tox_project: ToxProjectCreator) -> None:
        project = tox_project({"tox.ini": "", "pyproject.toml": ""})
        result = project.run("c", "-e", "py,.pkg", "-k", "package", "recreate", "--develop", "-r", "--no-recreate-pkg")
        expected = "[testenv:py]\npackage = editable\nrecreate = True\n\n[testenv:.pkg]\nrecreate = False\n"
>       assert result.out == expected
E       AssertionError: assert '.pkg: The --...ate = False\n' == '[testenv:py]...ate = False\n'
E         
E         + .pkg: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E         + .pkg: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E           [testenv:py]
E           package = editable
E           recreate = True
E           
E           [testenv:.pkg]
E           recreate = False

expected   = '[testenv:py]\npackage = editable\nrecreate = True\n\n[testenv:.pkg]\nrecreate = False\n'
project    = ToxProject(path=/tmp/pytest-of-churchyard/pytest-20/popen-gw8/test_show_config_cli_flag0/p) at 139675990924800
result     = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox c -e py,.pkg -k package recreate --dev...l is no longer bundled in virtualenv.
[testenv:py]
package = editable
recreate = True

[testenv:.pkg]
recreate = False

tox_project = <function init_fixture.<locals>._init at 0x7f08d9d93560>

tests/session/cmd/test_show_config.py:230: AssertionError
________________________ test_python_generate_hash_seed ________________________
[gw8] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f08d9dca8e0>

    def test_python_generate_hash_seed(tox_project: ToxProjectCreator) -> None:
        ini = "[testenv]\npackage=skip\ncommands=python -c 'import os; print(os.environ[\"PYTHONHASHSEED\"])'"
        prj = tox_project({"tox.ini": ini})
        result = prj.run("r", "-e", "py")
        result.assert_success()
>       assert 1 <= int(result.out.splitlines()[1]) <= (1024 if sys.platform == "win32" else 4294967295)
E       ValueError: invalid literal for int() with base 10: 'py: commands[0]> python -c \'import os; print(os.environ["PYTHONHASHSEED"])\''

ini        = '[testenv]\npackage=skip\ncommands=python -c \'import os; print(os.environ["PYTHONHASHSEED"])\''
prj        = ToxProject(path=/tmp/pytest-of-churchyard/pytest-20/popen-gw8/test_python_generate_hash_seed0/p) at 139675992437840
result     = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox r -e py
cwd: /tmp/pytest-of-churchyard...nviron["PYTHONHASHSEED"])'
435096058
  py: OK (0.12=setup[0.04]+cmd[0.08] seconds)
  congratulations :) (0.18 seconds)

tox_project = <function init_fixture.<locals>._init at 0x7f08d9dca8e0>

tests/tox_env/python/test_python_api.py:196: ValueError
__________________________ test_python_set_hash_seed ___________________________
[gw3] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f3593e21940>

    def test_python_set_hash_seed(tox_project: ToxProjectCreator) -> None:
        ini = "[testenv]\npackage=skip\ncommands=python -c 'import os; print(os.environ[\"PYTHONHASHSEED\"])'"
        prj = tox_project({"tox.ini": ini})
        result = prj.run("r", "-e", "py", "--hashseed", "10")
        result.assert_success()
>       assert result.out.splitlines()[1] == "10"
E       assert 'py: commands...HASHSEED"])\'' == '10'
E         
E         - 10
E         + py: commands[0]> python -c 'import os; print(os.environ["PYTHONHASHSEED"])'

ini        = '[testenv]\npackage=skip\ncommands=python -c \'import os; print(os.environ["PYTHONHASHSEED"])\''
prj        = ToxProject(path=/tmp/pytest-of-churchyard/pytest-20/popen-gw3/test_python_set_hash_seed0/p) at 139868161933872
result     = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox r -e py --hashseed 10
cwd: /tmp/pytest...nt(os.environ["PYTHONHASHSEED"])'
10
  py: OK (0.11=setup[0.04]+cmd[0.07] seconds)
  congratulations :) (0.19 seconds)

tox_project = <function init_fixture.<locals>._init at 0x7f3593e21940>

tests/tox_env/python/test_python_api.py:188: AssertionError
________________________ test_python_disable_hash_seed _________________________
[gw8] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f08d9d92e80>

    def test_python_disable_hash_seed(tox_project: ToxProjectCreator) -> None:
        ini = "[testenv]\npackage=skip\ncommands=python -c 'import os; print(os.environ.get(\"PYTHONHASHSEED\"))'"
        prj = tox_project({"tox.ini": ini})
        result = prj.run("r", "-e", "py", "--hashseed", "notset")
        result.assert_success()
>       assert result.out.splitlines()[1] == "None"
E       assert 'py: commands...HASHSEED"))\'' == 'None'
E         
E         - None
E         + py: commands[0]> python -c 'import os; print(os.environ.get("PYTHONHASHSEED"))'

ini        = '[testenv]\npackage=skip\ncommands=python -c \'import os; print(os.environ.get("PYTHONHASHSEED"))\''
prj        = ToxProject(path=/tmp/pytest-of-churchyard/pytest-20/popen-gw8/test_python_disable_hash_seed0/p) at 139675993198896
result     = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox r -e py --hashseed notset
cwd: /tmp/py...environ.get("PYTHONHASHSEED"))'
None
  py: OK (0.07=setup[0.03]+cmd[0.04] seconds)
  congratulations :) (0.13 seconds)

tox_project = <function init_fixture.<locals>._init at 0x7f08d9d92e80>

tests/tox_env/python/test_python_api.py:216: AssertionError
__________________________ test_python_keep_hash_seed __________________________
[gw3] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f3593e69080>

    def test_python_keep_hash_seed(tox_project: ToxProjectCreator) -> None:
        ini = """
        [testenv]
        package=skip
        set_env=PYTHONHASHSEED=12
        commands=python -c 'import os; print(os.environ["PYTHONHASHSEED"])'
        """
        result = tox_project({"tox.ini": ini}).run("r", "-e", "py")
        result.assert_success()
>       assert result.out.splitlines()[1] == "12"
E       assert 'py: commands...HASHSEED"])\'' == '12'
E         
E         - 12
E         + py: commands[0]> python -c 'import os; print(os.environ["PYTHONHASHSEED"])'

ini        = '\n    [testenv]\n    package=skip\n    set_env=PYTHONHASHSEED=12\n    commands=python -c \'import os; print(os.environ["PYTHONHASHSEED"])\'\n    '
result     = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox r -e py
cwd: /tmp/pytest-of-churchyard...nt(os.environ["PYTHONHASHSEED"])'
12
  py: OK (0.10=setup[0.03]+cmd[0.07] seconds)
  congratulations :) (0.21 seconds)

tox_project = <function init_fixture.<locals>._init at 0x7f3593e69080>

tests/tox_env/python/test_python_api.py:208: AssertionError
__________________ test_python_hash_seed_from_env_and_disable __________________
[gw3] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f3593e696c0>

    def test_python_hash_seed_from_env_and_disable(tox_project: ToxProjectCreator) -> None:
        ini = "[testenv]\npackage=skip\ncommands=python -c 'import os; print(os.environ.get(\"PYTHONHASHSEED\"))'"
        with patch.dict("os.environ", {"PYTHONHASHSEED": "16"}):
            result = tox_project({"tox.ini": ini}).run("r", "-e", "py", "--hashseed", "notset")
            result.assert_success()
>           assert result.out.splitlines()[1] == "None"
E           assert 'py: commands...HASHSEED"))\'' == 'None'
E             
E             - None
E             + py: commands[0]> python -c 'import os; print(os.environ.get("PYTHONHASHSEED"))'

ini        = '[testenv]\npackage=skip\ncommands=python -c \'import os; print(os.environ.get("PYTHONHASHSEED"))\''
result     = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox r -e py --hashseed notset
cwd: /tmp/py...environ.get("PYTHONHASHSEED"))'
None
  py: OK (0.07=setup[0.02]+cmd[0.05] seconds)
  congratulations :) (0.17 seconds)

tox_project = <function init_fixture.<locals>._init at 0x7f3593e696c0>

tests/tox_env/python/test_python_api.py:260: AssertionError
_________________ test_python_hash_seed_from_env_and_override __________________
[gw7] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7f72fd283420>

    def test_python_hash_seed_from_env_and_override(tox_project: ToxProjectCreator) -> None:
        ini = "[testenv]\npackage=skip\ncommands=python -c 'import os; print(os.environ.get(\"PYTHONHASHSEED\"))'"
        with patch.dict("os.environ", {"PYTHONHASHSEED": "14"}):
            result = tox_project({"tox.ini": ini}).run("r", "-e", "py", "--hashseed", "15")
            result.assert_success()
>           assert result.out.splitlines()[1] == "15"
E           assert 'py: commands...HASHSEED"))\'' == '15'
E             
E             - 15
E             + py: commands[0]> python -c 'import os; print(os.environ.get("PYTHONHASHSEED"))'

ini        = '[testenv]\npackage=skip\ncommands=python -c \'import os; print(os.environ.get("PYTHONHASHSEED"))\''
result     = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox r -e py --hashseed 15
cwd: /tmp/pytest...s.environ.get("PYTHONHASHSEED"))'
15
  py: OK (0.11=setup[0.04]+cmd[0.07] seconds)
  congratulations :) (0.16 seconds)

tox_project = <function init_fixture.<locals>._init at 0x7f72fd283420>

tests/tox_env/python/test_python_api.py:252: AssertionError
____________________________ test_skip_pkg_install _____________________________
[gw5] linux -- Python 3.13.3 .../tox/.tox/3.13/bin/python3

tox_project = <function init_fixture.<locals>._init at 0x7fa67721ba60>
demo_pkg_inline = PosixPath('.../tox/tests/demo_pkg_inline')

    def test_skip_pkg_install(tox_project: ToxProjectCreator, demo_pkg_inline: Path) -> None:
        proj = tox_project({"tox.ini": "[testenv]\npackage=wheel\n"})
        result_first = proj.run("--root", str(demo_pkg_inline), "--skip-pkg-install")
        result_first.assert_success()
>       assert result_first.out.startswith("py: skip building and installing the package"), result_first.out
E       AssertionError: .pkg: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E         .pkg: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer bundled in virtualenv.
E         py: skip building and installing the package
E           py: OK (0.00 seconds)
E           congratulations :) (0.10 seconds)
E         
E       assert False
E        +  where False = <built-in method startswith of str object at 0x7fa6774306f0>('py: skip building and installing the package')
E        +    where <built-in method startswith of str object at 0x7fa6774306f0> = '.pkg: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer b...tualenv.\npy: skip building and installing the package\n  py: OK (0.00 seconds)\n  congratulations :) (0.10 seconds)\n'.startswith
E        +      where '.pkg: The --no-wheel and --wheel options are deprecated. They have no effect for Python > 3.8 as wheel is no longer b...tualenv.\npy: skip building and installing the package\n  py: OK (0.00 seconds)\n  congratulations :) (0.10 seconds)\n' = code: 0\ncmd: .../tox/.tox/3.13/bin/python3 -m tox --root ...n virtualenv.\npy: skip building and installing the package\n  py: OK (0.00 seconds)\n  congratulations :) (0.10 seconds)\n.out

demo_pkg_inline = PosixPath('.../tox/tests/demo_pkg_inline')
proj       = ToxProject(path=/tmp/pytest-of-churchyard/pytest-20/popen-gw5/test_skip_pkg_install0/p) at 140352939769232
result_first = code: 0
cmd: .../tox/.tox/3.13/bin/python3 -m tox --root ...n virtualenv.
py: skip building and installing the package
  py: OK (0.00 seconds)
  congratulations :) (0.10 seconds)

tox_project = <function init_fixture.<locals>._init at 0x7fa67721ba60>

tests/session/cmd/test_sequential.py:288: AssertionError
=========================== short test summary info ============================
FAILED tests/plugin/test_plugin.py::test_plugin_hooks_and_order - AssertionEr...
FAILED tests/session/cmd/test_devenv.py::test_devenv_fail_multiple_target - A...
FAILED tests/session/cmd/test_show_config.py::test_show_config_py_ver_impl_constants
FAILED tests/session/cmd/test_show_config.py::test_show_config_cli_flag - Ass...
FAILED tests/tox_env/python/test_python_api.py::test_python_generate_hash_seed
FAILED tests/tox_env/python/test_python_api.py::test_python_set_hash_seed - a...
FAILED tests/tox_env/python/test_python_api.py::test_python_disable_hash_seed
FAILED tests/tox_env/python/test_python_api.py::test_python_keep_hash_seed - ...
FAILED tests/tox_env/python/test_python_api.py::test_python_hash_seed_from_env_and_disable
FAILED tests/tox_env/python/test_python_api.py::test_python_hash_seed_from_env_and_override
FAILED tests/session/cmd/test_sequential.py::test_skip_pkg_install - Assertio...

Environment

Provide at least:

  • OS: Fedora Linux 41 to 43, but presumably all
Output of pip list of the host Python, where tox is installed
Package               Version
--------------------- -------------------
anyio                 4.9.0
argon2-cffi           23.1.0
argon2-cffi-bindings  21.2.0
attrs                 25.3.0
build                 1.2.2.post1
cachetools            5.5.2
certifi               2025.4.26
cffi                  1.17.1
chardet               5.2.0
charset-normalizer    3.4.2
check-manifest        0.50
colorama              0.4.6
covdefaults           2.3.0
coverage              7.8.0
defusedxml            0.7.1
detect-test-pollution 1.2.0
devpi-client          7.2.0
devpi-common          4.0.4
devpi-process         1.0.2
devpi-server          6.14.0
diff-cover            9.2.4
distlib               0.3.9
execnet               2.1.1
filelock              3.18.0
flaky                 3.8.1
h11                   0.16.0
hatch-vcs             0.4.0
hatchling             1.27.0
httpcore              1.0.9
httpx                 0.28.1
hupper                1.12.1
idna                  3.10
iniconfig             2.1.0
itsdangerous          2.2.0
jinja2                3.1.6
lazy                  1.6
legacy-cgi            2.6.3
markupsafe            3.0.2
packaging             25.0
packaging-legacy      23.0.post0
passlib               1.7.4
pastedeploy           3.1.0
pathspec              0.12.1
pkginfo               1.12.1.2
plaster               1.1.2
plaster-pastedeploy   1.0.1
platformdirs          4.3.8
pluggy                1.5.0
psutil                7.0.0
py                    1.11.0
pycparser             2.22
pygments              2.19.1
pyproject-api         1.9.1
pyproject-hooks       1.2.0
pyramid               2.0.2
pytest                8.3.5
pytest-cov            6.1.1
pytest-mock           3.14.0
pytest-xdist          3.6.1
python-dateutil       2.9.0.post0
re-assert             1.1.0
regex                 2024.11.6
repoze-lru            0.7
requests              2.32.3
ruamel-yaml           0.18.10
setuptools            80.4.0
setuptools-scm        8.3.1
six                   1.17.0
sniffio               1.3.1
strictyaml            1.7.3
time-machine          2.16.0
tox                   0.1.dev849+g794e6be
translationstring     1.4
trove-classifiers     2025.5.9.12
urllib3               2.4.0
venusian              3.1.1
virtualenv            20.31.2
waitress              3.0.2
webob                 1.8.9
wheel                 0.45.1
zope-deprecation      5.1
zope-interface        7.2

Minimal example

$ tox -e 3.13 -- tests/plugin/test_plugin.py tests/session/cmd/test_devenv.py tests/session/cmd/test_sequential.py tests/session/cmd/test_show_config.py tests/tox_env/python/test_python_api.py tests/tox_env/python/test_python_runner.py -n auto
@hroncok
Copy link
Contributor Author

hroncok commented May 12, 2025

Should be fixed by #3528

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants