darksky
darksky

Reputation: 21039

virtualenv removing libraries (flask / yolk) on restart

I just started learning Flask (and as a result, getting into virtualenv as well). I followed a tutorial on Flask's documentation and created a small application. I installed Flask and yolk using venv and everything was working fine.

I restarted my computer and when I activated virtualenv again, flask and yolk were no longer recognised. I had to reinstall them via easy_install. Does venv remove any installed packages once the computer has been restarted?

What happened here? Is there anything I need to do from my side?

Upvotes: 1

Views: 410

Answers (1)

ravenac95
ravenac95

Reputation: 3637

As long as you're sourcing the virtualenv correctly and installing the packages correctly, your virtualenv should not be affected by a reboot. It's completely independent of that. There are one of three possibilities that I can think of that explains your issues:

  1. The incorrect virtualenv was sourced
  2. You installed flask and yolk onto the system python
  3. You used some kind of ephemeral storage

(The third is the least likely)

Upvotes: 2

Related Questions