1 votes

ImportError : Aucun module nommé debian.deb822

Mon installation Ubuntu 14.04 semble être désespérément défectueuse, à tel point que je ne peux plus installer aucun paquet à l'aide de apt-get install. L'erreur la plus fréquente est "no module named debian.deb822". Un exemple est donné ci-dessous. Notez que mon but n'est pas nécessairement d'installer ce paquet en particulier ; juste d'être capable d'installer cualquier paquets. Toute aide serait grandement appréciée !

box:~/python> sudo apt-get install update-notifier
Reading package lists... Done
Building dependency tree       
Reading state information... Done
apturl is already the newest version.
apturl-common is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 394 not upgraded.
5 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Setting up update-notifier-common (0.154.1ubuntu1) ...
Traceback (most recent call last):
  File "/usr/lib/update-notifier/package-data-downloader", line 26, in <module>
    import debian.deb822
ImportError: No module named debian.deb822
dpkg: error processing package update-notifier-common (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of update-notifier:
 update-notifier depends on update-notifier-common (= 0.154.1ubuntu1); however:
  Package update-notifier-common is not configured yet.

dpkg: error processing package update-notifier (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of update-manager:
 update-manager depends on update-notifier; however:
  Package update-notifier is not configured yet.

dpkg: error processing package update-manager (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of ubuntu-release-upgrader-gtk:
 ubuntu-release-upgrader-gtk depends on update-manager; however:
  Package update-manager is not configured yet.

dpkg: error processing package ubuntu-release-upgrader-gtk (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of ubuntu-desktop:
 ubuntu-desktop depends on ubuntu-releasNo apport report written because the error message indicates its a followup error from a previous failure.
                                                                  No apport report written because the error message indicates its a followup error from a previous failure.
            No apport report written because MaxReports is reached already
                                                                          No apport report written because MaxReports is reached already
                                                        e-upgrader-gtk; however:
  Package ubuntu-release-upgrader-gtk is not configured yet.
 ubuntu-desktop depends on update-manager; however:
  Package update-manager is not configured yet.
 ubuntu-desktop depends on update-notifier; however:
  Package update-notifier is not configured yet.

dpkg: error processing package ubuntu-desktop (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 update-notifier-common
 update-notifier
 update-manager
 ubuntu-release-upgrader-gtk
 ubuntu-desktop
E: Sub-process /usr/bin/dpkg returned an error code (1)

EDIT 1 : Après avoir exécuté "sudo apt-get update" et "sudo apt-get upgrade", la sortie est légèrement différente mais la même erreur est générée :

box:~> sudo apt-get upgrade update-notifier
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
update-notifier is already the newest version.
The following packages have been kept back:
  libreoffice libreoffice-base libreoffice-base-core libreoffice-base-drivers
  libreoffice-calc libreoffice-common libreoffice-core libreoffice-draw
  libreoffice-gnome libreoffice-gtk libreoffice-gtk3 libreoffice-help-en-us
  libreoffice-impress libreoffice-math libreoffice-style-galaxy
  libreoffice-style-human libreoffice-style-tango libreoffice-writer
  linux-generic linux-generic-lts-vivid linux-headers-generic
  linux-headers-generic-lts-vivid linux-image-generic
  linux-image-generic-lts-vivid linux-signed-generic-lts-vivid
  linux-signed-image-generic-lts-vivid linux-tools-virtual-lts-wily
  openjdk-8-jdk openjdk-8-jre openjdk-8-jre-headless python3-uno shim-signed
0 upgraded, 0 newly installed, 0 to remove and 32 not upgraded.
5 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Setting up update-notifier-common (0.154.1ubuntu1) ...
Traceback (most recent call last):
  File "/usr/lib/update-notifier/package-data-downloader", line 26, in <module>
    import debian.deb822
ImportError: No module named debian.deb822
dpkg: error processing package update-notifier-common (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of update-notifier:
 update-notifier depends on update-notifier-common (= 0.154.1ubuntu1); however:
  Package update-notifier-common is not configured yet.

dpkg: error processing package update-notifier (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of update-manager:
 update-manager depends on update-notifier; however:
  Package update-notifier is not configured yet.

dpkg: error processing package update-manager (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of ubuntu-release-upgrader-gtk:
 ubuntu-release-upgrader-gtk depends on update-manager; however:
  Package update-manager is not configured yet.

dpkg: error processing package ubuntu-release-upgrader-gtk (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of ubuntu-desktop:
 ubuntu-desktop depends on ubuntu-releasNo apport report written because the error message indicates its a followup error from a previous failure.
                                                                  No apport report written because the error message indicates its a followup error from a previous failure.
            No apport report written because MaxReports is reached already
                                                                          No apport report written because MaxReports is reached already
                                                        e-upgrader-gtk; however:
  Package ubuntu-release-upgrader-gtk is not configured yet.
 ubuntu-desktop depends on update-manager; however:
  Package update-manager is not configured yet.
 ubuntu-desktop depends on update-notifier; however:
  Package update-notifier is not configured yet.

dpkg: error processing package ubuntu-desktop (--configure):
 dependency problems - leaving unconfigured
E: Sub-process /usr/bin/dpkg returned an error code (1)

EDIT 2 : Après avoir exécuté les corrections suggérées par @Raphael, la sortie a quelque peu changé, mais le problème persiste :

box:~/Downloads> sudo apt-get install update-notifier
Reading package lists... Done
Building dependency tree       
Reading state information... Done
update-notifier is already the newest version.
The following packages were automatically installed and are no longer required:
  libreoffice-gtk3 linux-headers-3.13.0-77 linux-headers-3.13.0-77-generic
  linux-image-3.13.0-77-generic linux-image-extra-3.13.0-77-generic
  linux-lts-wily-tools-4.2.0-27 linux-tools-4.2.0-27-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
5 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Setting up update-notifier-common (0.154.1ubuntu1) ...
Traceback (most recent call last):
  File "/usr/lib/update-notifier/package-data-downloader", line 26, in <module>
    import debian.deb822
ImportError: No module named debian.deb822
dpkg: error processing package update-notifier-common (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of update-notifier:
 update-notifier depends on update-notifier-common (= 0.154.1ubuntu1); however:
  Package update-notifier-common is not configured yet.

dpkg: error processing package update-notifier (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of update-manager:
 update-manager depends on update-notifier; however:
  Package update-notifier is not configured yet.

dpkg: error processing package update-manager (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of ubuntu-release-upgrader-gtk:
 ubuntu-release-upgrader-gtk depends on update-manager; however:
  Package update-manager is not configured yet.

dpkg: error processing package ubuntu-release-upgrader-gtk (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of ubuntu-desktop:
 ubuntu-desktop depends on ubuntu-releasNo apport report written because the error message indicates its a followup error from a previous failure.
                                                                  No apport report written because the error message indicates its a followup error from a previous failure.
            No apport report written because MaxReports is reached already
                                                                          No apport report written because MaxReports is reached already
                                                        e-upgrader-gtk; however:
  Package ubuntu-release-upgrader-gtk is not configured yet.
 ubuntu-desktop depends on update-manager; however:
  Package update-manager is not configured yet.
 ubuntu-desktop depends on update-notifier; however:
  Package update-notifier is not configured yet.

dpkg: error processing package ubuntu-desktop (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 update-notifier-common
 update-notifier
 update-manager
 ubuntu-release-upgrader-gtk
 ubuntu-desktop
E: Sub-process /usr/bin/dpkg returned an error code (1)

1voto

Kreuzfeld Points 89

Le problème s'est avéré être que les paquets Python "deb822" et "apt" étaient installés, mais pas au bon endroit. J'ai (1) identifié l'emplacement de ces paquets en utilisant locate deb822 (2) ont identifié ce qu'ils "devraient" vivre :

python
import numpy
print numpy

puis (3) copier les fichiers dans le répertoire approprié via :

sudo cp -r /usr/lib/python2.7/dist-packages/apt* /appropriate_directory/python2.7/site-packages/
sudo cp -r /usr/lib/python2.7/dist-packages/deb* /appropriate_directory/python2.7/site-packages/

Après cela, sudo apt-get install X semble fonctionner parfaitement.

0voto

tlhIngan Points 341

Vous avez 394 paquets qui n'ont pas été mis à jour. Il s'agit probablement d'un problème de dépendance. Exécuter

sudo apt-get update
sudo apt-get upgrade

0voto

Raphael Points 7725

Von Forums Ubuntu :

C'est dû à la non-disponibilité du paquet python-six .

Pour l'installer, procédez comme suit :

sudo apt-get update; sudo apt-get install --reinstall python-six

EDIT 1 :-

Depuis, apt-get install ne semble pas fonctionner, vous pouvez l'installer manuellement en utilisant :

cd ~/Downloads; wget -c http://ftp.us.debian.org/debian/pool/main/s/six/python-six_1.10.0-3_all.deb; sudo dpkg -i python-six_1.10.0-3_all.deb

EDIT 2 :-

Von Debian :

Fichiers de contrôle d'un ou plusieurs paragraphes de type RFC822, par exemple debian/control, .changes, .dsc, Packages, Sources, Release, etc. (module debian.deb822)

Vous pourriez donc avoir besoin de ce paquet. Pour l'installer :

cd ~/Downloads; wget -c http://ftp.us.debian.org/debian/pool/main/p/python-debian/python-debian_0.1.28_all.deb; sudo dpkg -i python-six_1.10.0-3_all.deb

SistemesEz.com

SystemesEZ est une communauté de sysadmins où vous pouvez résoudre vos problèmes et vos doutes. Vous pouvez consulter les questions des autres sysadmins, poser vos propres questions ou résoudre celles des autres.

Powered by:

X