I had a problem when python could not find the modules installed by the peak, while in virtualenv.
I narrowed it down and found that when I call python , when my virtualenv is activated, it still reaches /usr/bin/python instead of /home/liam/dev/.virtualenvs/noots/bin/python .
When I use which python in virtualenv, I get:
/home/liam/dev/.virtualenvs/noots/bin/python
When I look at my $PATH variable in virtualenv, I get:
bash: /home/liam/dev/.virtualenvs/noots/bin:/home/liam/bin:/home/liam/.local/bin:/home/liam/bin:/home/liam/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin: No such file or directory
and yet, when I actually run python , it goes to /usr/bin/python
To make things more confusing for me, if I run python3.5 , it grabs python3.5 from the correct directory (i.e. /home/liam/dev/.virtualenvs/noots/bin/python3.5 )
I did not touch /home/liam/dev/.virtualenvs/noots/bin/ at all. python and python3.5 are still linked to python3 in this directory. Going to /home/liam/dev/.virtualenvs/noots/bin/ and starting ./python , ./python3 or ./python3.5 work fine.
I use virtualenvwrapper if that matters, however the problem seems to have occurred recently, long after installing virtualenv and virtualenvwrapper
source share