I am working with flask in a virtual environment. I was able to install matplotlib with pip, and I can import matplotlib
in a Python session. However, when I im
Although most answers seem to point towards patching the activate
script to use the system python, I was having trouble getting that to work and an easy solution for me - though a little cringey - was to install matplotlib to the global environment and use that instead of a virtualenv instance. You can do this either by creating your virtualenv with the --system-site-packages flag like virtualenv --system-site-packages foo
, or to use the universal flag when pip installing like pip install -U matplotlib
.