You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd like to run a tox env with an additional constraint on the dependencies. I'd like to do that directly in the invocation, either by specifying a command-line parameter or setting an environment variable.
All tox defaults can now be changed via an environment variable: TOX_ prefix followed by the settings key, e.g. TOX_PACKAGE=wheel.
Since package is defined at the same level as deps, I'd have expected that setting TOX_DEPS would have allowed overriding the testenv.deps, but it didn't. I also tried TOX_ENV_DEPS=pydantic>=2 and TOX_TEST_ENV_DEPS and TOX_TESTENV_DEPS, but none have any effect.
I also tried tox run -e py -x 'deps=pydantic>=2' along with other variants for -x, including testenv:py.deps=pydantic>=2, but none had any effect.
The current config specifies deps=, so overriding or extending requirements functions the same in this case, though what I really want is to constrain. What I don't want to do is have to generate a file (and clean it up later) in order to test.
Is this objective achievable with tox? Why are the documented expectations not met?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I'd like to run a tox env with an additional constraint on the dependencies. I'd like to do that directly in the invocation, either by specifying a command-line parameter or setting an environment variable.
Based on these docs:
Since
package
is defined at the same level asdeps
, I'd have expected that settingTOX_DEPS
would have allowed overriding thetestenv.deps
, but it didn't. I also triedTOX_ENV_DEPS=pydantic>=2
andTOX_TEST_ENV_DEPS
andTOX_TESTENV_DEPS
, but none have any effect.I also tried
tox run -e py -x 'deps=pydantic>=2'
along with other variants for-x
, includingtestenv:py.deps=pydantic>=2
, but none had any effect.The current config specifies
deps=
, so overriding or extending requirements functions the same in this case, though what I really want is to constrain. What I don't want to do is have to generate a file (and clean it up later) in order to test.Is this objective achievable with tox? Why are the documented expectations not met?
Beta Was this translation helpful? Give feedback.
All reactions