在Windows系统下用pip安装时,PremissionError错误解决办法
2017-05-02 17:32
691 查看
当用pip install package_name 语句直接安装时,出现如下报错:
此时应该采用 pip install --user package_name 语法进行安装:
C:\Users\wangz>pip install pygame Collecting pygame Using cached pygame-1.9.3-cp36-cp36m-win_amd64.whl Installing collected packages: pygame Exception: Traceback (most recent call last): File "c:\program files\python36\lib\site-packages\pip\basecommand.py", line 215, in main status = self.run(options, args) File "c:\program files\python36\lib\site-packages\pip\commands\install.py", line 342, in run prefix=options.prefix_path, File "c:\program files\python36\lib\site-packages\pip\req\req_set.py", line 784, in install **kwargs File "c:\program files\python36\lib\site-packages\pip\req\req_install.py", line 851, in install self.move_wheel_files(self.source_dir, root=root, prefix=prefix) File "c:\program files\python36\lib\site-packages\pip\req\req_install.py", line 1064, in move_wheel_files isolated=self.isolated, File "c:\program files\python36\lib\site-packages\pip\wheel.py", line 345, in move_wheel_files clobber(source, lib_dir, True) File "c:\program files\python36\lib\site-packages\pip\wheel.py", line 316, in clobber ensure_dir(destdir) File "c:\program files\python36\lib\site-packages\pip\utils\__init__.py", line 83, in ensure_dir os.makedirs(path) File "c:\program files\python36\lib\os.py", line 220, in makedirs mkdir(name, mode) PermissionError: [WinError 5] 拒绝访问。: 'c:\\program files\\python36\\Lib\\site-packages\\pygame'
此时应该采用 pip install --user package_name 语法进行安装:
C:\Users\wangz>pip install --user pygame Collecting pygame Using cached pygame-1.9.3-cp36-cp36m-win_amd64.whl Installing collected packages: pygame Successfully installed pygame-1.9.3
相关文章推荐
- 用U盘安装系统提示Windows 无法安装所需的文件。文件可能损坏或丢失错误代码:0x80070570解决办法
- C:\Windows\system32\MSVCR100.dll 没有被指定在 Windows 上运行,或者它包含错误。请尝试使用原始安装媒体重新安装程序,或联系您的系统管理员或软件供应商以获取支持。【解决办法】
- 在安装正版Windows7时输序列号提示错误的解决办法
- Windows系统安装otf(OpenType)字体提示字体文件损坏解决办法
- 安装ecshop网店系统常见错误及解决办法
- 如何在Ubuntu系统中重新安装不同版本的Ubuntu!(……Not a COM32R image ……“错误的解决办法!
- Virtualbox 安装Win8 server2008 R2 等系统的时候错误 0xc0000225的解决办法
- 关于 SQL 2005 安装程序无法获取ASPNET账户的系统账户信息 错误解决办法
- 针对win 7系统中matlab安装后出现的小错误解决办法
- windows 7硬盘安装Ubuntu 12.04 后出现grub,无法进入系统解决办法
- Windows系统搜索功能提示"意外错误,操作无法完成"解决办法
- 安装Microsoft Windows SDK 7.1时出现的错误(附解决办法)
- Windows下安装MySql后,出现的错误解决办法
- Windows 7 安装软件错误:“Error 1935 ...HRESULT: 0x800736FD” 的解决办法
- Windows 2003 安装/运行 Windows Live (MSN)错误解决办法
- devenv.exe - 系统错误无法启动此程序,因为计算机中丢失 MSVCR100.dll。尝试重新安装该程序以解决此问题。【解决办法】
- Windows下安装UCM文件系统的语义错误解决方法
- Windows 7 安装软件错误:“Error 1935 ...HRESULT: 0x800736FD” 的解决办法
- 在64位windows系统中Subclipse提示JavaHL找不到的错误的解决办法
- 解决双硬盘安装windows出现“安装程序无法定位现有系统分区,也无法创建新的系统分区”错误