IBMDataScience/DSx-Desktop

Not being able to uprade Bokeh in DSX Desktop due to a limitation to upgrade python-dateutil

Closed this issue · 4 comments

I'm trying to upgrade the installed version of Bokeh in DSX desktop (V1.2.0) in a MAC running 10.13.2 OS in order to use the latest version of Pixiedust; however, when I perform a !pip install --upgrade bokeh in a pyhton 2.7 notebook, I'm getting the following error, related to a problem to upgrade the python-dateutil library due to restricted access to the lib/python2.7 folder; is there any workaround this issue that I can use?

Collecting bokeh
Collecting python-dateutil>=2.1 (from bokeh)
Using cached python_dateutil-2.6.1-py2.py3-none-any.whl
Collecting tornado>=4.3 (from bokeh)
Collecting numpy>=1.7.1 (from bokeh)
Using cached numpy-1.14.0-cp27-cp27mu-manylinux1_x86_64.whl
Requirement already up-to-date: PyYAML>=3.10 in /opt/conda/lib/python2.7/site-packages (from bokeh)
Collecting Jinja2>=2.7 (from bokeh)
Using cached Jinja2-2.10-py2.py3-none-any.whl
Requirement already up-to-date: futures>=3.0.3 in /user-home/999/.local/lib/python2.7/site-packages (from bokeh)
Requirement already up-to-date: six>=1.5.2 in /user-home/999/.local/lib/python2.7/site-packages (from bokeh)
Requirement already up-to-date: singledispatch in /opt/conda/lib/python2.7/site-packages (from tornado>=4.3->bokeh)
Requirement already up-to-date: certifi in /user-home/999/.local/lib/python2.7/site-packages (from tornado>=4.3->bokeh)
Requirement already up-to-date: backports-abc>=0.4 in /opt/conda/lib/python2.7/site-packages (from tornado>=4.3->bokeh)
Collecting MarkupSafe>=0.23 (from Jinja2>=2.7->bokeh)
Installing collected packages: python-dateutil, tornado, numpy, MarkupSafe, Jinja2, bokeh
Found existing installation: python-dateutil 2.6.0
Uninstalling python-dateutil-2.6.0:
Exception:
Traceback (most recent call last):
File "/opt/conda/lib/python2.7/site-packages/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/opt/conda/lib/python2.7/site-packages/pip/commands/install.py", line 342, in run
prefix=options.prefix_path,
File "/opt/conda/lib/python2.7/site-packages/pip/req/req_set.py", line 778, in install
requirement.uninstall(auto_confirm=True)
File "/opt/conda/lib/python2.7/site-packages/pip/req/req_install.py", line 754, in uninstall
paths_to_remove.remove(auto_confirm)
File "/opt/conda/lib/python2.7/site-packages/pip/req/req_uninstall.py", line 115, in remove
renames(path, new_path)
File "/opt/conda/lib/python2.7/site-packages/pip/utils/init.py", line 267, in renames
shutil.move(old, new)
File "/opt/conda/lib/python2.7/shutil.py", line 300, in move
rmtree(src)
File "/opt/conda/lib/python2.7/shutil.py", line 252, in rmtree
onerror(os.remove, fullname, sys.exc_info())
File "/opt/conda/lib/python2.7/shutil.py", line 250, in rmtree
os.remove(fullname)
OSError: [Errno 13] Permission denied: '/opt/conda/lib/python2.7/site-packages/dateutil/_common.py'

@jpmora69 In order to install or upgrade any package you would need to use --user flag. So on the latest version of DSX (1.2.2) you should be able to upgrade bokeh using:
!pip install --upgrade --user bokeh

Hi @jpmora69, please let us know if your issue was resolved.

Thanks!

The Issue was resolved. Thank you for your help.

Glad to hear :)