Thanks for trying to help Steve I solved the problem, see my reply to @bayone
As for virtual environments, let me try and explain with my limited knowledge.
If you install a library globally, the installation might affect the entire system, for example, if the library you installed allows for whatever reason to use a command called
pacman (or any other existing command) that might create some conflicts with the existing system package that provides the same command.
Creating a virtual environment and installing libraries inside it gives you a controllable box where you know for certain the conditions your Python program runs on, this includes all the installed libraries, their versions and much more; you can easily recreate the same environment on any other machine. That solves the problem of “It works on my machine!”, which is one of the biggest reasons it is encouraged that you use a virtual environment.
The basic idea of virtual environments is isolating your python programs from everything else on the OS. in other words, if you install something on a particular virtual environment, you can only access whatever you installed inside the said environment which means you can’t access it anywhere else. and that reduces the problems related to package conflicts.
Furthermore, with virtual environments you can use multiple versions of the same library across different projects. for example, Project A can use
SQLAlchemy 1.1 and Project B can use
SQLAlchemy 1.2 without any of the projects knowing about what the other one uses.
So all in all, virtual environments are essential for any Python project, because installing stuff globally might cause some serious damage. And environments allow you to control the overall process of crafting your beautiful product
 That moment when you successfully finish your program and everything works as expected, only to get a load of errors when you install it on your friend’s computer.