Python Forum

Full Version: upgrading python package
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

I am new in python and I need please help. I use the python ezdxf package (ezdxf.readthedocs.io), I have installed the 0.8.1 version on my debian oldstable but the ezdxf 0.8.3 already exists, I have to upgrade.

So I did :

root@debian:/home/mojolicious# pip show ezdxf
---
Name: ezdxf
Version: 0.8.1
Location: /usr/local/lib/python2.7/dist-packages
Requires: pyparsing
root@debian:/home/mojolicious# pip install ezdxf --upgrade
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 290, 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 1097, in prepare_files
req_to_install, self.upgrade)
File "/usr/lib/python2.7/dist-packages/pip/index.py", line 292, in find_requirement
elif is_prerelease(version) and not (self.allow_all_prereleases or req.prereleases):
File "/usr/lib/python2.7/dist-packages/pip/util.py", line 739, in is_prerelease
return any([any([y in set(["a", "b", "c", "rc", "dev"]) for y in x]) for x in parsed])
TypeError: 'int' object is not iterable

Storing debug log for failure in /root/.pip/pip.log
root@debian:/home/mojolicious#

Can please someone help me ? I don't know what to do....

Best regards,

Amka
Bug report,it was a Debian bug.
This should be fixed now,upgrade pip.
pip install -U pip
Then version should be 9.0.1 pip -V
pip install -U ezdxf 
Hi,

Thanks a lot for reply but...

root@debian:/home/mojolicious# pip -V
pip 1.5.6 from /usr/lib/python2.7/dist-packages (python 2.7)
root@debian:/home/mojolicious# pip install -U pip
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 290, 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 1097, in prepare_files
req_to_install, self.upgrade)
File "/usr/lib/python2.7/dist-packages/pip/index.py", line 292, in find_requirement
elif is_prerelease(version) and not (self.allow_all_prereleases or req.prereleases):
File "/usr/lib/python2.7/dist-packages/pip/util.py", line 739, in is_prerelease
return any([any([y in set(["a", "b", "c", "rc", "dev"]) for y in x]) for x in parsed])
TypeError: 'int' object is not iterable

Storing debug log for failure in /root/.pip/pip.log
root@debian:/home/mojolicious# pip -V
pip 1.5.6 from /usr/lib/python2.7/dist-packages (python 2.7)
Try:
sudo apt-get update
sudo apt-get install python-dev build-essential
sudo apt-get install python-pip
Then:
pip install -U pip

From Python 3 that you should use,look at Linux Python 3 environment.
Hi,

Unfortunatly nothing new, it says that all is already ok :

One only thing : it says that build-essential (which is then already installed), is "passed into manulay installed".


root@debian:/home/mojolicious# apt-get install python-dev build-essential
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances
Lecture des informations d'état... Fait
build-essential est déjà la plus récente version disponible.
build-essential passé en « installé manuellement ».
python-dev est déjà la plus récente version disponible.
0 mis à jour, 0 nouvellement installés, 0 à enlever et 0 non mis à jour.
root@debian:/home/mojolicious# apt-get install python-pip
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances
Lecture des informations d'état... Fait
python-pip est déjà la plus récente version disponible.
0 mis à jour, 0 nouvellement installés, 0 à enlever et 0 non mis à jour.
root@debian:/home/mojolicious# pip install -U pip
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 290, 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 1097, in prepare_files
req_to_install, self.upgrade)
File "/usr/lib/python2.7/dist-packages/pip/index.py", line 292, in find_requirement
elif is_prerelease(version) and not (self.allow_all_prereleases or req.prereleases):
File "/usr/lib/python2.7/dist-packages/pip/util.py", line 739, in is_prerelease
return any([any([y in set(["a", "b", "c", "rc", "dev"]) for y in x]) for x in parsed])
TypeError: 'int' object is not iterable

Storing debug log for failure in /root/.pip/pip.log
root@debian:/home/mojolicious#
Your old pip version can be broken.
Try with older easy_install to upgrade pip.
easy_install -U pip