Blog Archives

Python Virtual Environments! Be safe!

Hi everyone,

You all know that lately I have been learning a bit of Python and one of the very first things that every single course says are: Create all your projects in a Python Virtual Environment. However, what does Virtual Environment mean?

When you do a default installation of Python, you can pretty much use it, install packages and create all your projects and this will work without any problems. The problem begins when a particular project of yours starts to have dependencies of a certain Python package in a certain level. If you run pip upgrade for a package in your global environment all projects that uses that one will get upgraded as well. The outcome from that are two possible results.

1) Your package is upgraded successfully and all projects that relates to that also work after.

2) Your package is upgraded successfully and some of your projects stops to work because of version compatibility. Read the rest of this entry