我试图在Python3设置上安装Pip3的一些软件包。 然而,我最终得到了一些我以前从未见过的错误。
我得到的错误是:
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_omega/IMDbPY
Storing debug log for failure in /home/omega/.pip/pip.log
我看到有些人建议更新,所以我做了并得到了这个:
omega@Omega-System:~$ pip3 install --upgrade setuptools
Downloading/unpacking setuptools from https://pypi.python.org/packages/3.4/s/setuptools/setuptools-14.3-py2.py3-none-any.whl#md5=fc7acea179a69c7d9bf8b854fe44b029
Downloading setuptools-14.3-py2.py3-none-any.whl (501kB): 501kB downloaded
Installing collected packages: setuptools
Found existing installation: setuptools 11.3.1
Uninstalling setuptools:
Cleaning up...
Exception:
Traceback (most recent call last):
File "/usr/lib/python3.4/shutil.py", line 522, in move os.rename(src, real_dst)
PermissionError: [Errno 13] Permission denied: '/usr/local/bin/easy_install' -> '/tmp/pip-h2lg1ase-uninstall/usr/local/bin/easy_install'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/pip/basecommand.py", line 122, in main
status = self.run(options, args)
File "/usr/lib/python3/dist-packages/pip/commands/install.py", line 283, in run
requirement_set.install(install_options, global_options, root=options.root_path)
File "/usr/lib/python3/dist-packages/pip/req.py", line 1431, in install
requirement.uninstall(auto_confirm=True)
File "/usr/lib/python3/dist-packages/pip/req.py", line 598, in uninstall
paths_to_remove.remove(auto_confirm)
File "/usr/lib/python3/dist-packages/pip/req.py", line 1836, in remove
renames(path, new_path)
File "/usr/lib/python3/dist-packages/pip/util.py", line 295, in renames
shutil.move(old, new)
File "/usr/lib/python3.4/shutil.py", line 535, in move os.unlink(src)
PermissionError: [Errno 13] Permission denied: '/usr/local/bin/easy_install'
Storing debug log for failure in /home/omega/.pip/pip.log
答案 0 :(得分:2)
您可以使用sudo pip3 args
。
PermissionError: [Errno 13] Permission denied: '/usr/local/bin/easy_install'
当您以非特权用户身份运行命令时,会出现此类错误。 /usr/local/bin
不属于您。它可能属于 root用户。