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 ran into a case where specifying a range of python in the env used for the mamba env update -n anaconda-client-env -f etc/example-environment-caching.yml step of the caching docs results in overriding the requested version of python passed to the setup-minicondapython-version action arg. In a hindsight-is-20/20 moment, it makes perfect sense that the update overrides things an bumps python to the maximum version specified in the range!
It's possible there are a few other manifestations of this symptom; at some point we managed to get python and python_abi having different versions due to this issue.
The solution I found is to instead take a five-step process so that the cache-free invocation of setup-miniconda always exploits the environment-file argument, which allows the python-version to be respected. Basically:
Check for a cache with lookup-only = true
If cache hit: run setup-miniconda without environment-file
If cache hit: restore cache
if cache not hit: run setup-minicondawithenvironment-file
if cache not hit: save cache
I made a repo demonstrating this, and as long as GitHub holds the run report, you can look and see that the docs approach has python upgrade while the careful approach outlined above retains the requested version.
The text was updated successfully, but these errors were encountered:
I ran into a case where specifying a range of
python
in the env used for themamba env update -n anaconda-client-env -f etc/example-environment-caching.yml
step of the caching docs results in overriding the requested version of python passed to thesetup-miniconda
python-version
action arg. In a hindsight-is-20/20 moment, it makes perfect sense that the update overrides things an bumps python to the maximum version specified in the range!It's possible there are a few other manifestations of this symptom; at some point we managed to get
python
andpython_abi
having different versions due to this issue.The solution I found is to instead take a five-step process so that the cache-free invocation of
setup-miniconda
always exploits theenvironment-file
argument, which allows thepython-version
to be respected. Basically:lookup-only = true
setup-miniconda
withoutenvironment-file
setup-miniconda
withenvironment-file
I made a repo demonstrating this, and as long as GitHub holds the run report, you can look and see that the docs approach has python upgrade while the careful approach outlined above retains the requested version.
The text was updated successfully, but these errors were encountered: