IndexError: índice de lista fora do intervalo ao instalar o iPython no Ubuntu 14.04

1

Estou seguindo este e estou recebendo:

gsamaras@gsamaras-A15:~$ sudo pip install "ipython[notebook]"
Downloading/unpacking ipython[notebook]
  Downloading ipython-4.2.0-py2-none-any.whl (736kB): 736kB downloaded
Requirement already satisfied (use --upgrade to upgrade): setuptools>=18.5 in /usr/local/lib/python2.7/dist-packages (from ipython[notebook])
Requirement already satisfied (use --upgrade to upgrade): decorator in /usr/lib/python2.7/dist-packages (from ipython[notebook])
Downloading/unpacking pickleshare (from ipython[notebook])
  Downloading pickleshare-0.7.2-py2.py3-none-any.whl
Downloading/unpacking traitlets (from ipython[notebook])
  Downloading traitlets-4.2.1-py2.py3-none-any.whl (67kB): 67kB downloaded
Requirement already satisfied (use --upgrade to upgrade): pexpect; sys_platform != "win32" in /usr/lib/python2.7/dist-packages (from ipython[notebook])
Downloading/unpacking simplegeneric>0.8 (from ipython[notebook])
  Downloading simplegeneric-0.8.1.zip
  Running setup.py (path:/tmp/pip_build_root/simplegeneric/setup.py) egg_info for package simplegeneric

Downloading/unpacking backports.shutil-get-terminal-size (from ipython[notebook])
  Downloading backports.shutil_get_terminal_size-1.0.0-py2.py3-none-any.whl
Cleaning up...
Exception:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 278, in run
    requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1091, in prepare_files
    req_to_install.check_if_exists()
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 811, in check_if_exists
    self.satisfied_by = pkg_resources.get_distribution(self.req)
  File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 535, in get_distribution
    dist = get_provider(dist)
  File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 415, in get_provider
    return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
IndexError: list index out of range

Storing debug log for failure in /home/gsamaras/.pip/pip.log

Como contornar isso?

Editar:

gsamaras@gsamaras-A15:~$ sudo pip install -U pip
Downloading/unpacking pip from https://pypi.python.org/packages/9c/32/004ce0852e0a127f07f358b715015763273799bd798956fa930814b60f39/pip-8.1.2-py2.py3-none-any.whl#md5=0570520434c5b600d89ec95393b2650b
  Downloading pip-8.1.2-py2.py3-none-any.whl (1.2MB): 1.2MB downloaded
Installing collected packages: pip
  Found existing installation: pip 1.5.4
    Not uninstalling pip at /usr/lib/python2.7/dist-packages, owned by OS
Successfully installed pip
Cleaning up...
    
por gsamaras 24.06.2016 / 21:18

1 resposta

2

Isso provavelmente é causado por ter uma versão desatualizada de pip . Você pode atualizar pip executando:

sudo pip install -U pip
    
por edwinksl 24.06.2016 / 21:31