"pip install django" gives an exception

I am trying to install django on Windows 10 using the "pip install django" command on the command line and this gives me this exception. What am I doing wrong here?

C:\Users\Amit>pip install django
Collecting django
  Using cached Django-1.9.2-py2.py3-none-any.whl
Installing collected packages: django
Exception:
Traceback (most recent call last):
  File "c:\program files (x86)\python35-32\lib\site-packages\pip\basecommand.py", line 209, in main
    status = self.run(options, args)
  File "c:\program files (x86)\python35-32\lib\site-packages\pip\commands\install.py", line 317, in run
    prefix=options.prefix_path,
  File "c:\program files (x86)\python35-32\lib\site-packages\pip\req\req_set.py", line 731, in install
    **kwargs
  File "c:\program files (x86)\python35-32\lib\site-packages\pip\req\req_install.py", line 841, in install
    self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
  File "c:\program files (x86)\python35-32\lib\site-packages\pip\req\req_install.py", line 1040, in move_wheel_files
    isolated=self.isolated,
  File "c:\program files (x86)\python35-32\lib\site-packages\pip\wheel.py", line 343, in move_wheel_files
    clobber(source, lib_dir, True)
  File "c:\program files (x86)\python35-32\lib\site-packages\pip\wheel.py", line 314, in clobber
    ensure_dir(destdir)
  File "c:\program files (x86)\python35-32\lib\site-packages\pip\utils\__init__.py", line 82, in ensure_dir
    os.makedirs(path)
  File "c:\program files (x86)\python35-32\lib\os.py", line 241, in makedirs
    mkdir(name, mode)
PermissionError: [WinError 5] Access is denied: 'c:\\program files (x86)\\python35-32\\Lib\\site-packages\\django'
+4
source share
1 answer

Installing Python packages requires an admin command line. Here's how to Start a command prompt as an administrator .

+4
source

Source: https://habr.com/ru/post/1629511/


All Articles