Skip to content
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

Be more selective in which system commands Anaconda overrides #372

Open
ncoghlan opened this issue Jul 6, 2015 · 4 comments
Open

Be more selective in which system commands Anaconda overrides #372

ncoghlan opened this issue Jul 6, 2015 · 4 comments

Comments

@ncoghlan
Copy link

ncoghlan commented Jul 6, 2015

(Relocated from conda/conda#1412)

When the Anaconda installer is configured to modify the user's .bashrc file, accessing shadowed system commands requires specifying the full path. Anaconda's scope means that this can lead to surprising consequence, where commands are shadowed when not expected, especially if there's a problem with the Anaconda version of the command (e.g. issue #307)

@asmeurer clarified that having source deactivate not work is deliberate (to avoid accidentally breaking invocation of conda and source activate), so my request is that the Anaconda binaries be split into two groups for default PATH modification purposes, a more tightly controlled and clearly documented subset which overrides system binaries (such as conda, and activate), and the full complement, which would be added to the end of PATH, ensuring their availability without shadowing the system versions.

Activating a conda environment would still ensure that the system versions were all shadowed, but side effects outside conda environments would be minimised.

@pitrou
Copy link

pitrou commented Jul 6, 2015

+1. I think this is highly desirable for anyone with a complex work environment.
I currently don't add the conda bin dir to my PATH, instead I make a symlink of the conda script into my ~/.local/bin. Otherwise too much stuff could get overriden by mistake (such as python itself, but also pip, openssl, sqlite3...).

@ncoghlan
Copy link
Author

ncoghlan commented Jul 7, 2015

Oops, I forgot to transfer the context where I discovered the issue:

A participant at a Software Carpentry bootcamp had tripped over #307 after enabling the .bashrc modifications when installing Anaconda, so the up arrow wasn't working for command scrollback when they ran sqlite3. Seeing readline not working on an Ubuntu system was rather confusing and it didn't occur to me to run /usr/bin/sqlite3 instead once which sqlite3 showed me sqlite3 was picking up the system version.

I'd had other folks complain to me that they'd found Anaconda frustrating when helping other people out at introductory programming workshops, and I'd now bet that this is the problem they were running into. I hadn't understood what they were complaining about previously, as I'd never encountered the optional .bashrc modifications.

@duozmo
Copy link

duozmo commented Dec 18, 2015

Is the name collision with virtualenv’s deactivate intentional?

@kalefranz
Copy link

With conda 4.4, we introduced conda activate and conda deactivate. While it'll take time, we have now have a deprecation path for the bare activate and deactivate commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants