-
-
Notifications
You must be signed in to change notification settings - Fork 526
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
--workdir override not working in tox >=4 #2654
Comments
Minimal reproducible: [tox]
toxworkdir=/tmp/blah ❯ tox c -k toxworkdir --core -e py --workdir a
[testenv:py]
[tox]
work_dir = /tmp/blah PR welcome with test and changelog. |
I tried to fix this but there doesn't seem to be an obvious way to differentiate if a parameter is passed or the default is called. That said: -x tox.toxworkdir=blah sorts the problem. |
I'm continuing the analysis from #2713. |
In #2725, I have a few commits that start to address this issue, but there are still a few test failures. Annoyingly, I can't even seem to get consistent test failures. A moment ago, It seems to me it's ill-defined what the value of The docs talk about a tox root and a package root. |
Relative to
Project root should default to Package root defaults to The core idea here would be to be able to run tox with
|
What is the difference between package root and project root? How is package root defined? Do I understand correctly that tox_root is always where the ini file is found? How can package root be changed? |
Always relative to the project root, it can be changed via the tox.ini config.
Yes.
By default is package root is the project root, but can be changed via tox.ini. |
What I mean to ask: what is the purpose of package root and project root compared to each other? What value would someone get by defining them separately? |
Packaging root is used by the package builder as the root directory. Project root is what tox uses as root directory. |
The problem is here Lines 96 to 110 in a36ff9d
the last else block is never called, and tox gets the toxworkdir from IniLoader and work_dir_builder as default is never called, so cli args dont take precedence over loaders
|
Issue
In tox <4 using --workdir would override whatever was in tox.ini, this no longer works in >= 4 which makes some CI/CD use cases difficult
Environment
Provide at least:
Minimal example
If possible, provide a minimal reproducer for the issue:
Tox 4:
Tox 3:
The text was updated successfully, but these errors were encountered: