Yum install python-pip centos

Fermé
diabloic Messages postés 141 Date d'inscription mardi 3 novembre 2009 Statut Membre Dernière intervention 28 juillet 2014 - 25 juin 2014 à 12:49
diabloic Messages postés 141 Date d'inscription mardi 3 novembre 2009 Statut Membre Dernière intervention 28 juillet 2014 - 27 juin 2014 à 00:16
Bonjour,

Lorsque j'exécute mon script sur mon serveur debian, il fonctionne parfaitement mais j'ai cette erreur lorsque je l'exécute sur mon serveur centos.
Ce script me sert à parser des fichiers xml.

./import.py fichier.xml
Traceback (most recent call last):
File "./import.py", line 39, in <module>
title = data.find(".//title//FreeText[@xml:lang='"+lang+"']", namespaces=namespaces).text
TypeError: find() got an unexpected keyword argument 'namespaces'

Je pense qu'il me faut installer le package "python-pip" mais le yum install pyhton-pip me retourne :

yum install python-pip
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: centos.crazyfrogs.org
* extras: centos.crazyfrogs.org
* updates: centos.crazyfrogs.org
Setting up Install Process
No package python-pip available.
Error: Nothing to do

J'ai bien regarder avant de poster ce message.
Je pense qu'il faut rajouter la bonne repository mais je ne sais ni comment ni laquelle.

Je vous remercie par avance.
A voir également:

4 réponses

zipe31 Messages postés 36402 Date d'inscription dimanche 7 novembre 2010 Statut Contributeur Dernière intervention 27 janvier 2021 6 407
25 juin 2014 à 13:06
0
diabloic Messages postés 141 Date d'inscription mardi 3 novembre 2009 Statut Membre Dernière intervention 28 juillet 2014 5
Modifié par diabloic le 25/06/2014 à 20:58
Salut!

Merci je n'avais pas la première partie, je l'aurais pourtant vu si j'avais bien lu l'ensemble!

Maintenant j'ai ce problème la, je commence ma recherche la :

pip install elementtree
Downloading/unpacking elementtree
Cannot fetch index base URL https://pypi.org/simple/
Could not find any downloads that satisfy the requirement elementtree
No distributions at all found for elementtree

Je me demande si c'est pas parce qu'il y a un proxy.
0
diabloic Messages postés 141 Date d'inscription mardi 3 novembre 2009 Statut Membre Dernière intervention 28 juillet 2014 5
25 juin 2014 à 21:17
Peut-on faire cette installation autrement, en récupérant un .rpm par exemple?
0
diabloic Messages postés 141 Date d'inscription mardi 3 novembre 2009 Statut Membre Dernière intervention 28 juillet 2014 5
25 juin 2014 à 22:45
/usr/bin/pip run on Thu Jun 26 00:40:18 2014
Downloading/unpacking elementtree

Getting page https://pypi.org/simple/elementtree/
Could not fetch URL https://pypi.python.org/simple/elementtree/: <urlopen error [Errno -2] Name or service not known>
Will skip URL https://pypi.org/simple/elementtree/ when looking for download links for elementtree
Getting page https://pypi.org/simple/
Could not fetch URL https://pypi.python.org/simple/: <urlopen error [Errno -2] Name or service not known>
Will skip URL https://pypi.org/simple/ when looking for download links for elementtree
Cannot fetch index base URL https://pypi.org/simple/

URLs to search for versions for elementtree:
* https://pypi.org/simple/elementtree/
Getting page https://pypi.org/simple/elementtree/
Could not fetch URL https://pypi.python.org/simple/elementtree/: <urlopen error [Errno -2] Name or service not known>
Will skip URL https://pypi.org/simple/elementtree/ when looking for download links for elementtree
Could not find any downloads that satisfy the requirement elementtree

Merci pour votre aide
J'ai tenté le pip --proxy .... elementtree mais ça n'a pas fonctionné
0
diabloic Messages postés 141 Date d'inscription mardi 3 novembre 2009 Statut Membre Dernière intervention 28 juillet 2014 5
25 juin 2014 à 23:39
J'ai configuré le
export https_proxy

Voici l'erreur maintenant
pip install elementtree
Downloading/unpacking elementtree
Could not find any downloads that satisfy the requirement elementtree
No distributions at all found for elementtree
Storing complete log in /root/.pip/pip.log

Et voici les log

/usr/bin/pip run on Thu Jun 26 01:32:44 2014
Downloading/unpacking elementtree

Getting page https://pypi.org/simple/elementtree/
URLs to search for versions for elementtree:
* https://pypi.org/simple/elementtree/
Getting page http://effbot.org/downloads
Could not fetch URL http://effbot.org/downloads#elementtree (from https://pypi.python.org/simple/elementtree/): <urlopen error [Errno -2] Name or service not known>
Will skip URL http://effbot.org/downloads#elementtree when looking for download links for elementtree
Getting page http://effbot.org/zone/element-index.htm
Could not fetch URL http://effbot.org/zone/element-index.htm (from https://pypi.python.org/simple/elementtree/): <urlopen error [Errno -2] Name or service not known>
Will skip URL http://effbot.org/zone/element-index.htm when looking for download links for elementtree
Analyzing links from page https://pypi.org/simple/elementtree/
Skipping link http://effbot.org/downloads#elementtree (from https://pypi.python.org/simple/elementtree/); not a file
Skipping link http://effbot.org/zone/element-index.htm (from https://pypi.python.org/simple/elementtree/); unknown archive format: .htm
Could not find any downloads that satisfy the requirement elementtree

No distributions at all found for elementtree

Exception information:
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/pip/basecommand.py", line 139, in main
status = self.run(options, args)
File "/usr/lib/python2.6/site-packages/pip/commands/install.py", line 266, in run
requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
File "/usr/lib/python2.6/site-packages/pip/req.py", line 1026, in prepare_files
url = finder.find_requirement(req_to_install, upgrade=self.upgrade)
File "/usr/lib/python2.6/site-packages/pip/index.py", line 171, in find_requirement
raise DistributionNotFound('No distributions at all found for %s' % req)
DistributionNotFound: No distributions at all found for elementtree
0
zipe31 Messages postés 36402 Date d'inscription dimanche 7 novembre 2010 Statut Contributeur Dernière intervention 27 janvier 2021 6 407
26 juin 2014 à 08:41
Salut,

Je ne sais que te dire ;-\
Je ne connais pas assez pip pour en déduire la moindre info de tes messages d'erreurs ;-(

Essaie une install plus verbeuse en rajoutant
-vvv
peut être y verrons-nous des infos qui nous manquent ?

pip install elementtree -vvv
0
diabloic Messages postés 141 Date d'inscription mardi 3 novembre 2009 Statut Membre Dernière intervention 28 juillet 2014 5
26 juin 2014 à 09:05
Salut et merci,

Malheureusement ça ne fait que donner des informations sur se trouvant dans le fichier de log :
Downloading/unpacking elementtree
Getting page https://pypi.org/simple/elementtree/
Could not fetch URL https://pypi.python.org/simple/elementtree/: <urlopen erro r [Errno -2] Name or service not known>
Will skip URL https://pypi.org/simple/elementtree/ when looking for dow nload links for elementtree
Getting page https://pypi.org/simple/
Could not fetch URL https://pypi.python.org/simple/: <urlopen error [Errno -2] Name or service not known>
Will skip URL https://pypi.org/simple/ when looking for download links for elementtree
Cannot fetch index base URL https://pypi.org/simple/
URLs to search for versions for elementtree:
* https://pypi.org/simple/elementtree/
Getting page https://pypi.org/simple/elementtree/
Could not fetch URL https://pypi.python.org/simple/elementtree/: <urlopen erro r [Errno -2] Name or service not known>
Will skip URL https://pypi.org/simple/elementtree/ when looking for dow nload links for elementtree
Could not find any downloads that satisfy the requirement elementtree
No distributions at all found for elementtree
Exception information:
Traceback (most recent call last):
File "/usr/lib/python2.6/site-packages/pip/basecommand.py", line 139, in main
status = self.run(options, args)
File "/usr/lib/python2.6/site-packages/pip/commands/install.py", line 266, in run
requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundl e=self.bundle)
File "/usr/lib/python2.6/site-packages/pip/req.py", line 1026, in prepare_file s
url = finder.find_requirement(req_to_install, upgrade=self.upgrade)
File "/usr/lib/python2.6/site-packages/pip/index.py", line 171, in find_requir ement
raise DistributionNotFound('No distributions at all found for %s' % req)
DistributionNotFound: No distributions at all found for elementtree
0
zipe31 Messages postés 36402 Date d'inscription dimanche 7 novembre 2010 Statut Contributeur Dernière intervention 27 janvier 2021 6 407
26 juin 2014 à 10:22
Re-

Alors essaie une installation directe depuis les sources ;-\
0
diabloic Messages postés 141 Date d'inscription mardi 3 novembre 2009 Statut Membre Dernière intervention 28 juillet 2014 5
27 juin 2014 à 00:16
Re,

oui j''étais justement sur le site.

Mais je n'ai pas trop compris comment faire.

Je regarde ça

Merci
0