Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mac: OSError: [Errno 1] Operation not permitted: '/tmp/pip-XcfgD6-uninstall/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/six-1.4.1-py2.7.egg-info' #64

Closed
tiansiyuan opened this issue Nov 10, 2015 · 16 comments

Comments

@tiansiyuan
Copy link

No description provided.

@tiansiyuan
Copy link
Author

Uninstalling six-1.4.1:
Exception:
Traceback (most recent call last):
File "/Library/Python/2.7/site-packages/pip-7.1.2-py2.7.egg/pip/basecommand.py", line 211, in main
status = self.run(options, args)
File "/Library/Python/2.7/site-packages/pip-7.1.2-py2.7.egg/pip/commands/install.py", line 311, in run
root=options.root_path,
File "/Library/Python/2.7/site-packages/pip-7.1.2-py2.7.egg/pip/req/req_set.py", line 640, in install
requirement.uninstall(auto_confirm=True)
File "/Library/Python/2.7/site-packages/pip-7.1.2-py2.7.egg/pip/req/req_install.py", line 716, in uninstall
paths_to_remove.remove(auto_confirm)
File "/Library/Python/2.7/site-packages/pip-7.1.2-py2.7.egg/pip/req/req_uninstall.py", line 125, in remove
renames(path, new_path)
File "/Library/Python/2.7/site-packages/pip-7.1.2-py2.7.egg/pip/utils/init.py", line 315, in renames
shutil.move(old, new)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py", line 302, in move
copy2(src, real_dst)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py", line 131, in copy2
copystat(src, dst)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py", line 103, in copystat
os.chflags(dst, st.st_flags)
OSError: [Errno 1] Operation not permitted: '/tmp/pip-XcfgD6-uninstall/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/six-1.4.1-py2.7.egg-info'

@mrry
Copy link
Contributor

mrry commented Nov 10, 2015

I'm not sure exactly what command you're running, but you'll probably need administrator privileges to uninstall from that directory. Try running the same command again prefixed by sudo.

@vrv
Copy link

vrv commented Nov 10, 2015

Also: see #11 for common OS X installation issues.

Edit: sorry, I meant https://github.com/tensorflow/tensorflow/blob/master/tensorflow/g3doc/get_started/os_setup.md#on-macosx-

@tiansiyuan
Copy link
Author

@tiansiyuan
Copy link
Author

it relates to uninstalling six 1.4.1

@tiansiyuan
Copy link
Author

I install python via brew and now it works.

So we can say that it does not work with the default python on MacOS 10.11.1 (15B42)

@spk921
Copy link

spk921 commented Nov 10, 2015

I got this error following , I follow all issues in the github. I did upgarded six , $ pip install 'protobuf>=3.0.0a3'and brew installed python but got follwoing error while installing it.

Exception:
Traceback (most recent call last):
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/basecommand.py", line 211, in main
status = self.run(options, args)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/commands/install.py", line 305, in run
wb.build(autobuilding=True)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/wheel.py", line 705, in build
self.requirement_set.prepare_files(self.finder)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/req/req_set.py", line 334, in prepare_files
functools.partial(self._prepare_file, finder))
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/req/req_set.py", line 321, in _walk_req_to_install
more_reqs = handler(req_to_install)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/req/req_set.py", line 491, in _prepare_file
session=self.session)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/download.py", line 825, in unpack_url
session,
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/download.py", line 673, in unpack_http_url
from_path, content_type = _download_http_url(link, session, temp_dir)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/download.py", line 857, in _download_http_url
stream=True,
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/_vendor/requests/sessions.py", line 477, in get
return self.request('GET', url, *_kwargs)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/download.py", line 373, in request
return super(PipSession, self).request(method, url, *args, *_kwargs)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/_vendor/requests/sessions.py", line 465, in request
resp = self.send(prep, *_send_kwargs)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/_vendor/requests/sessions.py", line 573, in send
r = adapter.send(request, *_kwargs)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/_vendor/cachecontrol/adapter.py", line 46, in send
resp = super(CacheControlAdapter, self).send(request, **kw)
File "/Users/sangpil_kim/tensorflow/lib/python2.7/site-packages/pip/_vendor/requests/adapters.py", line 431, in send
raise SSLError(e, request=request)
SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)

However, I solved problem by downloading .whl file manually ( https://storage.googleapis.com/tensorflow/mac/tensorflow-0.5.0-py2-none-any.whl ) and run $pip install tensorflow-0.5.0-py2-none-any.whl

I don't know why but it worked

@jctobin
Copy link

jctobin commented Nov 10, 2015

It worked because there have been issues with openssl, python2.7.10, and homebrew. By downloading it manually you avoided the Requests part that is currently problematic between between the three

@javierfdr
Copy link

Actually entering the url manually in a browser you can see there is no SSL certificate enabled for the site.
It works if you do:

pip install http://storage.googleapis.com/tensorflow/mac/tensorflow-0.5.0-py2-none-any.whl 

(this is changing https by http).

@vrv
Copy link

vrv commented Nov 13, 2015

Closing for now as there seems to be some resolution here (though using an esoteric solution).

@vrv vrv closed this as completed Nov 13, 2015
ilblackdragon added a commit to ilblackdragon/tensorflow that referenced this issue Mar 9, 2016
Continue working on neural translation model tensorflow#9. Added language model example tensorflow#64
@gimlyu
Copy link

gimlyu commented Apr 21, 2016

the best way is use virtualenv , not use python env of system default. [Just walk on by]

@ateixeiramunoz
Copy link

I finally did it like this, when reading this link

sudo -H pip install https://storage.googleapis.com/tensorflow/mac/tensorflow-0.5.0-py2-none-any.whl --upgrade --ignore-installed

@whitebread
Copy link

Solved it via @ateixeiramunoz 's comment

@AIROBOTAI
Copy link

@ateixeiramunoz 's answer worked. --upgrade --ignore-installed is the key.

@CrashRain
Copy link

@ateixeiramunoz 's answer works perfectly

@saliksyed
Copy link

Thanks @ateixeiramunoz -- worked for me as well.

lissyx added a commit to lissyx/tensorflow that referenced this issue Apr 14, 2018
tensorflow-copybara pushed a commit that referenced this issue Aug 8, 2019
http://llvm.org/docs/LangRef.html#unreachable-instruction

Closes #64

COPYBARA_INTEGRATE_REVIEW=tensorflow/mlir#64 from schweitzpgi:unreachable-op 8c6d2828dc4aacc6073383722c74be6a8129bf50
PiperOrigin-RevId: 262301557
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests