Project

General

Profile

Tâche #22970

Scénario #22741: Traitement express MEN (05-07)

Corriger l'erreur python qui s'affiche dans Query-Auto pour certaines erreurs

Added by Joël Cuissinat over 5 years ago. Updated over 5 years ago.

Status:
Fermé
Priority:
Normal
Assigned To:
Start date:
02/01/2018
Due date:
% Done:

100%

Estimated time:
2.00 h
Spent time:
Remaining (hours):
0.0

Description

Actuellement, lorsque l'on utilise les serveurs de mise à jour Ubuntu du crihan, on obtient l'erreur suivante :

root@proxy:~# Query-Auto -U ftp.crihan.fr
Mise à jour le jeudi 01 février 2018 16:26:20
*** eolebase 2.6.2 (0000000A) ***

Configuration du dépôt Ubuntu avec la source ftp.crihan.fr
Configuration du dépôt EOLE avec la source test-eole.ac-dijon.fr
Action update pour root                                                                                                                                                                                           
pyeole.pkg - Erreur rencontrée :
E: Impossible de récupérer http://ftp.crihan.fr/ubuntu/dists/xenial/main/i18n/Translation-fr  404  Not Found
E: Impossible de récupérer http://ftp.crihan.fr/ubuntu/dists/xenial-security/main/i18n/Translation-en  404  Not Found
E: Impossible de récupérer http://ftp.crihan.fr/ubuntu/dists/xenial-updates/main/i18n/Translation-en  404  Not Found
E: Le téléchargement de quelques fichiers d'index a échoué, ils ont été ignorés, ou les anciens ont été utilisés à la place.

Maj-Auto - local variable 'proc' referenced before assignment

Associated revisions

Revision aedb25df (diff)
Added by Emmanuel GARETTE over 5 years ago

pkg.py : gestion des erreurs de mise à jour en mode silent (ref #22970)

History

#1 Updated by Joël Cuissinat over 5 years ago

La correction suivante me paraît la moins risquée, mais dans ce cas précis le message est en double :

root@proxy:~# diff -uNr pkg.py.ori /usr/lib/python2.7/dist-packages/pyeole/pkg.py 
--- pkg.py.ori    2018-02-01 17:08:41.680227643 +0100
+++ /usr/lib/python2.7/dist-packages/pyeole/pkg.py    2018-02-01 17:08:56.612280653 +0100
@@ -427,7 +427,8 @@
         proc.wait()
         code = proc.returncode
     if code != 0:
-        stderr = proc.stderr.read()
+        if not silent:
+            stderr = proc.stderr.read()
         # ticket #17482 make error message great again
         if stderr.strip() == "E: There were unauthenticated packages and -y was used without --allow-unauthenticated":
             stderr = _(u"There were unauthenticated packages and Maj-Auto has prevented their installation").encode('UTF-8')

#2 Updated by Joël Cuissinat over 5 years ago

  • Remaining (hours) changed from 2.0 to 1.5

#3 Updated by Emmanuel GARETTE over 5 years ago

  • Status changed from Nouveau to En cours

#4 Updated by Emmanuel GARETTE over 5 years ago

  • Assigned To set to Emmanuel GARETTE

#5 Updated by Emmanuel GARETTE over 5 years ago

  • % Done changed from 0 to 100
  • Remaining (hours) changed from 1.5 to 0.25

#6 Updated by Scrum Master over 5 years ago

  • Status changed from En cours to Résolu

#7 Updated by Joël Cuissinat over 5 years ago

  • Status changed from Résolu to Fermé
  • Remaining (hours) changed from 0.25 to 0.0

Commit présent uniquement dans master => nouveau paquet python-pyeole 2.7.0-1

Also available in: Atom PDF