Search code examples
pythonmatplotliboserror

ERROR: Could not install packages due to an OSError: [WinError 5] Access denied


I installed the package matplotlib for a project and everything worked fine. After a pull from github i got introduced with the following error: ModuleNotFoundError: No module named 'matplotlib.artist'.

I then tried to reinstall matplotlib with this code in the terminal : python3 -m pip install matplotlib. I tried pip upgrade and other things but this error kept returning :

ERROR: Could not install packages due to an OSError: [WinError 5] Access denied

Is there anybody that has an idea how to fix this?

Picture:


Solution

  • Do this first if second step throws error

    python3 -m pip install matplotlib --user