-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Activating a conda environment using conda
instead of source
#1882
Comments
Re-classifying as an enhancement since the old ways still work, they have simply introduced a new way of doing this. |
the old way doesn't work for me. If I am following the new way of adding the conda to the environment, the old way doesn't work anymore. I am getting an error: |
Anaconda's shell scripts that they have you source as part of the new approach must be clobbering something then. The problem is that we can't leave old users behind and blindly cut over to this new approach, so if we're going to support both we are going to have to add detection code for what version of Anaconda someone is using which complicates things. |
@eyadsibai BTW, if you need to shut off our automatic activation then see https://code.visualstudio.com/docs/python/environments#_activate-an-environment-in-the-terminal for the |
Another snafu in all of this is that this new approach is only documented for UNIX-based operating systems and not for Windows at all. |
@brettcannon thanks, but I like that feature 😅 , I hope it can be resolved soon. |
@eyadsibai it's not that simple because we don't have that kind of access to the terminal, i.e. we just get to send in text to execute and that's pretty much it. So we will have to do detection on the TypeScript side of things to figure out the right approach. Could you do us a favour and let us know if executing that shell script multiple times causes an issue? E.g. if we blindly executed it and then the |
It looks like this approach is entirely for UNIX only; Windows is still only for Command Prompt and still through the |
And final comment: conda has not updated their docs on activating an environment yet. |
@brettcannon, is there anything left to "verify" here? |
@ericsnowcurrently yep, it was to verify that if you follow conda's current documentation does it break our approach to conda environment activation (i.e. does adding the recommended stuff to your shell break us). |
BTW, I tried out miniconda 4.4.0+ on Windows and it worked fine. So we don't need to change anything there. |
I'm assuming this is with |
correct |
I'm creating an issue for Windows + Conda |
@ericsnowcurrently |
We adjust to changes in 4.4.0.
Fails on a Mac |
I modified the code, and found that it still fails.
Next, I re-enabled the above in my bash_profile. I.e. for @ericsnowcurrently @brettcannon /cc We might have to review the solution for Mac & Linux. |
We are going to try going back to |
cat /opt/cloudera/parcels/Anaconda/etc/profile.d/conda.sh
Should Helmus folder be created for everyone using Anaconda? I am very curious on this. |
I am not able to activate the new env. I am using conda 4.4.10 I am using command: conda activate
If I followed the instruction in the above error output, I got new error prompted in the output below:
So what it the secret command to activate an environment? My Anaconda is 4.4.Thank you very much. |
Please file your issue against conda, they'll be able to assist you with your issue. |
Environment data
Actual behavior
I am using the zsh shell. When I create a new python terminal it uses
source activate 'name_of_environment'
Expected behavior
I am using the zsh shell. When I create a new python terminal it uses
conda activate 'name_of_environment
Steps to reproduce:
The text was updated successfully, but these errors were encountered: