Não é possível instalar ou remover nada no Ubuntu 16.04 porque py3clean e py3compile não foram encontrados

3

Não consigo instalar ou atualizar nada no Ubuntu 16.04.Estou faltando o pacote python3-software-properties e não consigo instalá-lo. Eu postei os vários tracebacks. Eu tentei instalar esses pacotes e recebi esses erros.

sarfraz@sarfraz:~$ sudo apt-get install --reinstall dpkg
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
language-selector-common language-selector-gnome python3-distupgrade           
python3-software-properties software-properties-common software-  properties-gtk
Recommended packages:
unattended-upgrades
The following packages will be upgraded:language-selector-common
language-selector-gnome python3-distupgrade python3-software-
properties software-properties-common software-properties-gtk
6 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 30 not     upgraded.
 141 not fully installed or removed.
Need to get 2,083 kB/2,496 kB of archives.
After this operation, 1,024 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://in.archive.ubuntu.com/ubuntu xenial-updates/main amd64     dpkg amd64 1.18.4ubuntu1.1 [2,083 kB]
Fetched 2,083 kB in 3s (617 kB/s) 
(Reading database ... 220260 files and directories currently installed.)
Preparing to unpack .../language-selector-gnome_0.165.4_all.deb ...
/var/lib/dpkg/info/language-selector-gnome.prerm: 6:         /var/lib/dpkg/info/language-selector-gnome.prerm: py3clean: not found
dpkg: warning: subprocess old pre-removal script returned error exit    status 127
dpkg: trying script from the new package instead ...
/var/lib/dpkg/tmp.ci/prerm: 6: /var/lib/dpkg/tmp.ci/prerm: py3clean:  not found
dpkg: error processing archive /var/cache/apt/archives/language-selector-gnome_0.165.4_all.deb (--unpack):
 subprocess new pre-removal script returned error exit status 127
/var/lib/dpkg/info/language-selector-gnome.postinst: 6:     /var/lib/dpkg/info/language-selector-gnome.postinst: py3compile: not found
dpkg: error while cleaning up:
subprocess installed post-installation script returned error exit status 127
Preparing to unpack .../dpkg_1.18.4ubuntu1.1_amd64.deb ...
Unpacking dpkg (1.18.4ubuntu1.1) over (1.18.4ubuntu1.1) ...
Errors were encountered while processing:
/var/cache/apt/archives/language-selector-gnome_0.165.4_all.deb
sarfraz@sarfraz:~$ sudo apt-get install python3-minimal
Reading package lists... Done
Building dependency tree       
Reading state information... Done
python3-minimal is already the newest version (3.5.1-3).
The following additional packages will be installed:
language-selector-common language-selector-gnome python3-distupgrade    
python3-software-properties software-properties-common software- properties-gtk
Recommended packages:
  unattended-upgrades
The following packages will be upgraded:
  language-selector-common language-selector-gnome python3-distupgrade  python3-software-properties software-properties-common software- properties-gtk
6 upgraded, 0 newly installed, 0 to remove and 30 not upgraded.
141 not fully installed or removed.
Need to get 0 B/413 kB of archives.
After this operation, 1,024 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database ... 220260 files and directories currently installed.)
Preparing to unpack .../language-selector-gnome_0.165.4_all.deb ...
/var/lib/dpkg/info/language-selector-gnome.prerm: 6:         /var/lib/dpkg/info/language-selector-gnome.prerm: py3clean: not found
dpkg: warning: subprocess old pre-removal script returned error exit status 127
dpkg: trying script from the new package instead ...
/var/lib/dpkg/tmp.ci/prerm: 6: /var/lib/dpkg/tmp.ci/prerm: py3clean: not found
dpkg: error processing archive /var/cache/apt/archives/language-    selector-gnome_0.165.4_all.deb (--unpack):
 subprocess new pre-removal script returned error exit status 127
/var/lib/dpkg/info/language-selector-gnome.postinst: 6:     /var/lib/dpkg/info/language-selector-gnome.postinst: py3compile: not found
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit     status 127
Preparing to unpack .../language-selector-common_0.165.4_all.deb ...
/var/lib/dpkg/info/language-selector-common.prerm: 21:     /var/lib/dpkg/info/language-selector-common.prerm: py3clean: not found
dpkg: warning: subprocess old pre-removal script returned error exit     status 127
dpkg: trying script from the new package instead ...
/var/lib/dpkg/tmp.ci/prerm: 21: /var/lib/dpkg/tmp.ci/prerm: py3clean: not found
dpkg: error processing archive /var/cache/apt/archives/language-    selector-common_0.165.4_all.deb (--unpack):
 subprocess new pre-removal script returned error exit status 127
/var/lib/dpkg/info/language-selector-common.postinst: 23:    /var/lib/dpkg/info/language-selector-common.postinst: py3compile: not   found
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit status 127
Errors were encountered while processing:
 /var/cache/apt/archives/language-selector-gnome_0.165.4_all.deb
 /var/cache/apt/archives/language-selector-common_0.165.4_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
sarfraz@sarfraz:~$ sudo apt-get install libssl-dev openssl
Reading package lists... Done
Building dependency tree       
Reading state information... Done
libssl-dev is already the newest version (1.0.2g-1ubuntu4.1).
openssl is already the newest version (1.0.2g-1ubuntu4.1).
The following additional packages will be installed:
  language-selector-common language-selector-gnome python3-distupgrade     python3-software-properties software-properties-common software-    properties-gtk
Recommended packages:
  unattended-upgrades
The following packages will be upgraded:
  language-selector-common language-selector-gnome python3-distupgrade     python3-software-properties software-properties-common software-  properties-gtk
6 upgraded, 0 newly installed, 0 to remove and 30 not upgraded.
141 not fully installed or removed.
Need to get 0 B/413 kB of archives.
After this operation, 1,024 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
 (Reading database ... 220260 files and directories currently installed.)
Preparing to unpack .../language-selector-gnome_0.165.4_all.deb ...
/var/lib/dpkg/info/language-selector-gnome.prerm: 6:     /var/lib/dpkg/info/language-selector-gnome.prerm: py3clean: not found
 dpkg: warning: subprocess old pre-removal script returned error exit status 127
dpkg: trying script from the new package instead ...
/var/lib/dpkg/tmp.ci/prerm: 6: /var/lib/dpkg/tmp.ci/prerm: py3clean: not found
dpkg: error processing archive /var/cache/apt/archives/language-    selector-gnome_0.165.4_all.deb (--unpack):
subprocess new pre-removal script returned error exit status 127
/var/lib/dpkg/info/language-selector-gnome.postinst: 6:     /var/lib/dpkg/info/language-selector-gnome.postinst: py3compile: not found
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit status 127
Preparing to unpack .../language-selector-common_0.165.4_all.deb ...
/var/lib/dpkg/info/language-selector-common.prerm: 21:     /var/lib/dpkg/info/language-selector-common.prerm: py3clean: not found
dpkg: warning: subprocess old pre-removal script returned error exit status 127
dpkg: trying script from the new package instead ...
 /var/lib/dpkg/tmp.ci/prerm: 21: /var/lib/dpkg/tmp.ci/prerm: py3clean: not found
dpkg: error processing archive /var/cache/apt/archives/language-selector-common_0.165.4_all.deb (--unpack):
 subprocess new pre-removal script returned error exit status 127
/var/lib/dpkg/info/language-selector-common.postinst: 23:     /var/lib/dpkg/info/language-selector-common.postinst: py3compile: not found
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit     status 127
Errors were encountered while processing:
 /var/cache/apt/archives/language-selector-gnome_0.165.4_all.deb
 /var/cache/apt/archives/language-selector-common_0.165.4_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
sarfraz@sarfraz:~$ sudo apt-get update && sudo apt-get dist-upgrade -y
Ign:1 http://dl.google.com/linux/chrome/deb stable InRelease
Hit:2 http://dl.google.com/linux/chrome/deb stable Release
Hit:4 http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu xenial InRelease  
Hit:5 http://ppa.launchpad.net/webupd8team/sublime-text-3/ubuntu xenial InRelease
Reading package lists... Done
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: The package python3-software-properties needs to be reinstalled, but I can't find an archive for it.
sarfraz@sarfraz:~$ sudo apt-get install --reinstall python-software-properties
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: The package python3-software-properties needs to be reinstalled, but I can't find an archive for it.
sarfraz@sarfraz:~$ sudo apt-get install --reinstall python-software-properties
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: The package python3-software-properties needs to be reinstalled, but I can't find an archive for it.
sarfraz@sarfraz:~$ sudo apt-get install software-properties-common 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: The package python3-software-properties needs to be reinstalled, but I can't find an archive for it.
sarfraz@sarfraz:~$ sudo apt-get install --reinstall python3-software-properties
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: The package python3-software-properties needs to be reinstalled, but I can't find an archive for it.
sarfraz@sarfraz:~$ sudo dpkg -i Downloads/python3-software-properties_0.92.36_all.deb 
(Reading database ... 220260 files and directories currently installed.)
Preparing to unpack .../python3-software-properties_0.92.36_all.deb ...
/var/lib/dpkg/info/python3-software-properties.prerm: 6:     /var/lib/dpkg/info/python3-software-properties.prerm: py3clean: not found
dpkg: error processing archive Downloads/python3-software-    properties_0.92.36_all.deb (--install):
 subprocess installed pre-removal script returned error exit status 127
/var/lib/dpkg/info/python3-software-properties.postinst: 6:      /var/lib/dpkg/info/python3-software-properties.postinst: py3compile: not found
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit status 127
Errors were encountered while processing:
 Downloads/python3-software-properties_0.92.36_all.deb
sarfraz@sarfraz:~$ sudo apt-get update
Ign:1 http://dl.google.com/linux/chrome/deb stable InRelease
Hit:2 http://dl.google.com/linux/chrome/deb stable Release
Hit:4 http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu xenial InRelease
Hit:5 http://ppa.launchpad.net/webupd8team/sublime-text-3/ubuntu xenial InRelease
Reading package lists... Done
sarfraz@sarfraz:~$ sudo apt-get install --reinstall python3
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: The package python3-software-properties needs to be reinstalled, but I can't find an archive for it.

A ajuda será apreciada.

    
por Sarfraz Ahmad 20.08.2016 / 15:51

1 resposta

0

Tente executar o seguinte comando:

apt-get  -f install

para corrigir um sistema com dependências quebradas.

Experimente também: dpkg --configure -a .

Se acima não ajudar, tente reinstalar a instalação principal do Python, pois o arquivo py3compile faz parte do pacote python3-minimal , portanto, se você ainda tiver o problema, tente reinstalar esse pacote. Se você não pode reinstalar usando apt-get , tente baixar o arquivo .pkg do kernel. org e instale manualmente (python3-minimal *). Por exemplo,

dpkg -i python3-minimal_*.deb

Verifique também se py3compile está acessível com base na variável atual PATH .

    
por kenorb 01.11.2017 / 16:00