windows下pip安装模块报错

在windows下用pip安装模块时,报错

C:\Users\llc>CommunityCommunityCommunity

C:\Users\llc>pip install django==1.10.6
Collecting django==1.10.6
  Using cached Django-1.10.6-py2.py3-none-any.whl
Installing collected packages: django
Exception:
Traceback (most recent call last):
  File "c:\program files\python35\lib\site-packages\pip\basecommand.py", line 209, in main
    status = self.run(options, args)
  File "c:\program files\python35\lib\site-packages\pip\commands\install.py", line 317, in run
    prefix=options.prefix_path,
  File "c:\program files\python35\lib\site-packages\pip\req\req_set.py", line 732, in install
    **kwargs
  File "c:\program files\python35\lib\site-packages\pip\req\req_install.py", line 835, in install
    self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
  File "c:\program files\python35\lib\site-packages\pip\req\req_install.py", line 1030, in move_wheel_files
    isolated=self.isolated,
  File "c:\program files\python35\lib\site-packages\pip\wheel.py", line 344, in move_wheel_files
    clobber(source, lib_dir, True)
  File "c:\program files\python35\lib\site-packages\pip\wheel.py", line 315, in clobber
    ensure_dir(destdir)
  File "c:\program files\python35\lib\site-packages\pip\utils\__init__.py", line 83, in ensure_dir
    os.makedirs(path)
  File "c:\program files\python35\lib\os.py", line 241, in makedirs
    mkdir(name, mode)
PermissionError: [WinError 5] 拒绝访问。: 'c:\\program files\\python35\\Lib\\site-packages\\django'
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.

权限错误,拒绝访问.

解决:

1. 右击python文件夹点击属性,安全。

2. 选择用户,点击编辑,勾选完全控制和修改。应用----确定

 

posted @ 2017-07-25 16:10  (KeeP)  阅读(238)  评论(0编辑  收藏  举报