gpt4 book ai didi

python - pip3 的 PermissionError

转载 作者:IT老高 更新时间:2023-10-28 20:29:55 29 4
gpt4 key购买 nike

这是我尝试使用 pip3 获取任何内容时出现的错误我不知道该怎么办

Exception:
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 1435, in install
requirement.install(install_options, global_options, *args, **kwargs)
File "/usr/lib/python3/dist-packages/pip/req.py", line 671, in install
self.move_wheel_files(self.source_dir, root=root)
File "/usr/lib/python3/dist-packages/pip/req.py", line 901, in move_wheel_files
pycompile=self.pycompile,
File "/usr/lib/python3/dist-packages/pip/wheel.py", line 206, in move_wheel_files
clobber(source, lib_dir, True)
File "/usr/lib/python3/dist-packages/pip/wheel.py", line 193, in clobber
os.makedirs(destsubdir)
File "/usr/lib/python3.4/os.py", line 237, in makedirs
mkdir(name, mode)
PermissionError: [Errno 13] Permission denied: '/usr/local/lib/python3.4/dist- packages/Django-1.7.2.dist-info'

Storing debug log for failure in /home/omega/.pip/pip.log

最佳答案

只需使用 --user 选项安装它们,该选项仅为当前用户而不是所有用户安装软件包

pip install xxxxxx --user

关于python - pip3 的 PermissionError,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27849412/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com