-
Notifications
You must be signed in to change notification settings - Fork 149
Remove python version pin from conda specs #786
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
Conversation
|
With the current configuration this leads to Jenkins running all tests with Python 3.11 and I think for now it should stay at 3.9 there. #!/bin/bash -e
mamba remove --name climada_env --all
mamba env create -f <(sed 's/ - python.*$/ - python=3.9/' requirements/env_climada.yml) --name climada_env
source activate climada_env
python -m pip install -e "./[test]"
make install_test
conda deactivatebut it doesn't look so nice, does it? |
|
Damn, sorry about that! 🙈 In the tests, I was relying on adding specs to the environment file definitions, see docs and https://github.com/CLIMADA-project/climada_python/blob/main/.github/workflows/ci.yml#L42 Apparently, this is an exclusive feature of micromamba. With Conda/Mamba, one can only define environments by either package specs or an environment file, but never both at the same time. Edit: does not work, see below |
|
Oh no, the solution above still upgrades Python in |
|
@emanuel-schmid This works, but it's annoying because it first creates the environment with Python 3.11 and then re-installs all packages for Python 3.9: |
|
Can we maybe just remove the Python version? We have a version requirement in the setup.py. The only issue is that the error of a wrong version will trigger only after creating an environment |
|
Removing the Python In any case we should update the Advanced Instrucions as well, otherwise they result in an environment with the Python version from the base environment. We certainly don't want that for Python 3.12 or 3.8. |
|
should be: "Removing the whole Python entry seems to work" |
|
Alright. So the resolution is
@chahank Is that okay for you? |
|
Hihi! I think the Otherwise good for me. |
|
Yes, of course, we will list the supported versions (3.9, 3.10, 3.11 at the moment) ✌️ |
* Add instructions for choosing Python version. * Fix update instructions: No env_developer.yml for Petals anymore. * Add setup instructions to VSCode for Petals.
|
Thanks @peanutfun . So, we have to remember to ALWAYS update this line with new releases. I think the naming is a bit confusing though with |
|
I did not want to call the other Python versions "Supported", because that implies that we can support people with any kind of issues occurring with these versions. I think we are not ready for that, yet. |
…A-project/climada_python into remove-python-version-pin
Co-authored-by: Emanuel Schmid <51439563+emanuel-schmid@users.noreply.github.com>
Er - how is that? |
|
@chahank Are you referring to Python releases? These occur once a year. |
|
I am referring to CLIMADA release. We have to update these installation instructions in case we support new versions of Python and if we do not support any more other versions. |
Changes proposed in this PR:
PR Author Checklist
develop)PR Reviewer Checklist