1

I've somehow messed up my python installation, while trying to update to Ubuntu 19.04 from 18.10.

The python command points to my anaconda's python instead of /usr/bin/python.

> which python
/home/username/anaconda3/bin/python

My $PATH:

--> echo $PATH
/home/username/.nvm/versions/node/v11.13.0/bin:/home/username/anaconda3/bin:/home/username/anaconda3/condabin:/usr/local/cuda-9.0/bin:/home/username/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin}

.bashrc:

cat .bashrc | grep anaconda
__conda_setup="$(CONDA_REPORT_ERRORS=false '/home/username/anaconda3/bin/conda' shell.bash hook 2> /dev/null)"
    if [ -f "/home/username/anaconda3/etc/profile.d/conda.sh" ]; then
        . "/home/username/anaconda3/etc/profile.d/conda.sh"
        \export PATH="/home/username/anaconda3/bin:$PATH"

cat .bashrc | grep python
nothing

cat .bashrc | grep PATH
export PATH=/usr/local/cuda-9.0/bin${PATH:+:$PATH}}
export LD_LIBRARY_PATH=/usr/local/cuda-9.0/lib64${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
        \export PATH="/home/username/anaconda3/bin:$PATH"

2
  • What is your $PATH?
    – Renan
    Apr 30, 2019 at 12:05
  • Oh wow, I've actually thought I've added it. I've just edited my question.
    – Roman
    Apr 30, 2019 at 12:08

1 Answer 1

0

Change your $PATH to put the system directories (/usr/bin, /bin etc...) before your Anaconda install. Probably it's set somewhere in your .bashrc.

2
  • I've just edited my question adding with the output of my bashr grepping anaconda
    – Roman
    Apr 30, 2019 at 12:40
  • 1
    removing the anaconda script in .bashrc fixed it
    – Roman
    Apr 30, 2019 at 12:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .