After I upgraded to El Capitan, Python 2.7 cannot install / update / remove some packages, but so far it still works fine for some other packages.
Below (end), an error message appears that I received while trying to update numpy. The same error occurs when you try to delete it.
I tried installing pip --user or pip install - installed noign, but it does not work. Even if he says that numpy was successfully installed, the version remains unchanged and it really does not update.
I know that other solutions can reinstall python using brew, but I want, if possible, to avoid multiple versions of Python. Any help would be appreciated.
----------- Error message -----------
40: 523: runtime error. The directory "/ Users / - / Library / Caches / pip / http" or its parent directory does not belong to the current user, and the cache is disabled. Check permissions and owner of this directory. If you use pud with sudo, you may need the sudo -H flag.
DEPRECATION: Removing an installed distutils (numpy) project is deprecated and will be removed in a future version. This is because deleting the distutils project will result in the partial removal of the project. Exception: Traceback (last last call): File "/Library/Python/2.7/site-packages/pip/basecommand.py", line 211, basically status = self.run (options, args) File "/ Library / Python /2.7/site-packages/pip/commands/install.py ", line 311, at startup root = options.root_path, File" /Library/Python/2.7/site-packages/pip/req/req_set.py ", line 640, in the installation requirement.uninstall (auto_confirm = True) file "/Library/Python/2.7/site-packages/pip/req/req_install.py", line 716, when deleting paths_to_remove.remove (auto_confirm) file "/ Library / Python / 2.7 / site-packages / pip / req / req_uninstall.py ", line 125, renames (path, new_path) File" /Library/Python/2.7/site-packages/pip/utils/ init .py ", line 315, when renaming shutil.move (old, new) yl "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py", line 302, in motion 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 allowed: '/ var / folders / m0 / hzt3nk9d43n05bwm6zztqjkh0000gn / T / pip-HESb5m-uninstall / System /Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy- 1.8.0rc1-py2.7.egg-info "(2)