我试图安装google python-client包,使用终端和
pip install --upgrade google-api-python-client
同样的结果
sudo -H pip install --upgrade google-api-python-client
我还发现,有人建议采用这样的方法:
sudo chown -R zkid18 /Users/zkid18/Library/Logs/pip
chown: /Users/zkid18/Library/Logs/pip: No such file or directory
和
sudo chown -R zkid18 /Users/zkid18/Library/Cashes/pip
chown: /Users/zkid18/Library/Cashes/pip: No such file or directory
Tje相同的结果,当我通过Pycharm安装时,我的异常
例外:回溯(最近一次调用):文件"/Library/Python/2.7/site-packages/pip/basecommand.py",第215行,在主状态=self.run(选项,args)文件"/Library/Python/2.7/site-packages/pip/commands/install.py",行317,在运行prefix=options.prefix_path,文件"/Library/Python/2.7/site-packages/pip/req/req_set.py",第736行,在安装"/Library/Python/2.7/site-packages/pip/req/req_install.py",(auto_confirm=True)文件的第742行,在卸载paths_to_remove.remove(auto_confirm)文件的第115行中,在删除重命名(path,new_path)文件的第267行中,在重新命名"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py",(旧的,新的)文件第302行,在移动copy2(src,real_dst)文件"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py",行131中,在copy2 copystat(src )中文件"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py",行103,在copystat os.chflags(dst,st.st_flags) OSError: Errno 1操作不允许:'/tmp/pip-uxDRkx-uninstall/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/six-1.4.1-py2.7.egg-info‘
发布于 2016-08-09 01:14:12
用虚拟化安装
virtualenv temp
source temp/bin/activate
pip install --upgrade google-api-python-client
或者忽略六个
sudo pip install --upgrade google-api-python-client --ignore-installed six
https://stackoverflow.com/questions/38840114
复制相似问题