python - Error in pip install matplotlib in Mac -


when

pip install matplotlib --upgrade --user 

i dont error program fails saying

traceback (most recent call last):   file "forest.py", line 22, in <module>     matplotlib.style.use('ggplot') attributeerror: 'module' object has no attribute 'style' 

when try upgrade matplotlib without --user following error

$ pip install matplotlib --upgrade  collecting matplotlib   using cached matplotlib-1.5.2-cp27-cp27m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl requirement up-to-date: cycler in /users/vangapellisanthosh/library/python/2.7/lib/python/site-packages (from matplotlib) collecting pyparsing!=2.0.0,!=2.0.4,!=2.1.2,>=1.5.6 (from matplotlib)   using cached pyparsing-2.1.8-py2.py3-none-any.whl collecting pytz (from matplotlib)   using cached pytz-2016.6.1-py2.py3-none-any.whl collecting numpy>=1.6 (from matplotlib)   using cached numpy-1.11.1-cp27-cp27m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl collecting python-dateutil (from matplotlib)   using cached python_dateutil-2.5.3-py2.py3-none-any.whl collecting 6 (from cycler->matplotlib)   using cached six-1.10.0-py2.py3-none-any.whl installing collected packages: pyparsing, pytz, numpy, six, python-dateutil, matplotlib   found existing installation: pyparsing 2.0.1     deprecation: uninstalling distutils installed project (pyparsing) has been deprecated , removed in future version. due fact uninstalling distutils project partially uninstall project.     uninstalling pyparsing-2.0.1: exception: traceback (most recent call last):   file "/library/python/2.7/site-packages/pip-8.1.2-py2.7.egg/pip/basecommand.py", line 215, in main     status = self.run(options, args)   file "/library/python/2.7/site-packages/pip-8.1.2-py2.7.egg/pip/commands/install.py", line 317, in run     prefix=options.prefix_path,   file "/library/python/2.7/site-packages/pip-8.1.2-py2.7.egg/pip/req/req_set.py", line 736, in install     requirement.uninstall(auto_confirm=true)   file "/library/python/2.7/site-packages/pip-8.1.2-py2.7.egg/pip/req/req_install.py", line 742, in uninstall     paths_to_remove.remove(auto_confirm)   file "/library/python/2.7/site-packages/pip-8.1.2-py2.7.egg/pip/req/req_uninstall.py", line 115, in remove     renames(path, new_path)   file "/library/python/2.7/site-packages/pip-8.1.2-py2.7.egg/pip/utils/__init__.py", line 267, 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: '/var/folders/7j/19zzrqpn5dl6ghw1pms6k2m80000gp/t/pip-fediky-uninstall/system/library/frameworks/python.framework/versions/2.7/extras/lib/python/pyparsing-2.0.1-py2.7.egg-info' 

how solve it?

try

sudo pip install matplotlib --upgrade --ignore-installed 6 

using pip install packages os x el capitan or greater has spawned generic problem. solution works has worked me.


Comments

Popular posts from this blog

java - Jasper subreport showing only one entry from the JSON data source when embedded in the Title band -

serialization - Convert Any type in scala to Array[Byte] and back -

SonarQube Plugin for Jenkins does not find SonarQube Scanner executable -