WindowsError: [Error 5] Access is denied: Anaconda Python Pip Installs and Upgrade

I was trying to run a pip install ( pip install scikit-learn) and I encountered this error:

This is the bit we are interested in ”

if you look at the error it states “WindowsError”

Hence the Access Denied error is due to not having the right level of privileges to carry out the installs or upgrade.

SOLUTION

Open Command Prompt as Administrator (with Administrator rights)

  1. Now run your pip installs and the windowsError should disappear and installation go through

  2. Hope this helps you 🙂
Want more information like this?

Similar Posts

  • | |

    Running a Classification Tree – Decision Tree – Data Analysis and Intrepretation

    Overview My research work deals with Ghana, a country from the Gapminder dataset as has already been discussed from the beginning and progression through this course. Picture Of My Final Decision Tree Outputted From My Python Program   The variables in my observation dataset are all quantitative. For the purposes of this assignment, I have binned…

  • Array Transposition – Numpy Python Data Analysis

    Welcome Guys, We will be looking at Array transposition in this quick notes. This is part of lectures on Learning Python for Data Analysis and Visualization by Jose Portilla on Udemy.   In [1]:

      In [2]:

      Out[2]:

    In [17]:

      Out[17]:

    In [10]:

      Out[10]:

    In [11]:

      Out[11]:

    In [23]:

     

  • Aggregation – Pandas Numpy Python Series DataFrame

      In this quick notes, we will go through aggregation in Python. This is part of lectures on Learning Python for Data Analysis and Visualization by Jose Portilla on Udemy.

      url = “http://archive.ics.uci.edu/ml/machine-learning-databases/wine-quality/” In [2]:

      In [4]:

      Out[4]: fixed acidity volatile acidity citric acid residual sugar chlorides free sulfur dioxide total sulfur dioxide density…

  • | |

    Testing a Basic Linear Regression Model – Data Analysis and Intrepretation

    Testing a Basic Linear Regression Model Background My research work deals with Ghana, a country from the Gapminder dataset as has already been discussed from the beginning and progression through this course.     1)     Program  Code and Output

           #####################     OUTPUT BEGIN  #####################     Axes(0.125,0.125;0.775×0.775) Describe the centered…

  • Read_csv Is Not Returning A Dataframe Python Pandas

    I was working with a CSV file on a project and after reading the CSV into the Program with the pandas.read_csv function the returned data type seemed not be a Dataframe for some reason code was as follows: sample = pd.read_csv(‘sample.csv’) When i tried to run some functions on the supposed ‘returned dataframe object -sample’ I…

  • ImportError: No module named learn.base Crab Python Fix

    I was working on Recommender System and had a problem when i tried importing from scikits.crab.recommenders.knn import UserBasedRecommender. I encountered the following error ImportError: No module named learn.base I did research on the web and found one good solution but it was in Chinese. Here is the link and credit to the original fixer :…

2 Comments

  1. I am running as administrator. Still I have this error.

    File “c:\python27\lib\site-packages\pip\_vendor\retrying.py”, line 200, in call
    attempt = Attempt(fn(*args, **kwargs), attempt_number, False)
    File “c:\python27\lib\site-packages\pip\utils\__init__.py”, line 102, in rmtree
    onerror=rmtree_errorhandler)
    File “c:\python27\lib\shutil.py”, line 252, in rmtree
    onerror(os.remove, fullname, sys.exc_info())
    File “c:\python27\lib\site-packages\pip\utils\__init__.py”, line 110, in rmtree_errorhandler
    if os.stat(path).st_mode & stat.S_IREAD:
    WindowsError: [Error 5] Access is denied: ‘c:\\users\\XXXX\\appdata\\local\\temp\\pip-vawmxw-unpack\\pytz-2017.2-py2.py3-none-any.whl’

    1. Hi Aneesh,
      Can you check that the file is not being accessed or opened by any other program.
      Sometimes the file might be accessed by another program without you realising. A simple case of restart and running command prompt as an administrator might help solve it

Leave a Reply

Your email address will not be published. Required fields are marked *