Dpkg:处理程序包时出错:程序包处于非常糟糕的不一致状态;您应该在尝试配置之前重新安装它

5vf7fwbs  于 2022-09-20  发布在  其他
关注(0)|答案(1)|浏览(186)

我想做的是:

sudo apt-get update && sudo apt-get upgrade

但我收到以下错误:

dpkg: error processing package python3-pip (--configure):
 package is in a very bad inconsistent state; you should
 reinstall it before attempting configuration

dpkg: error processing package python3-setuptools (--configure):
 package is in a very bad inconsistent state; you should
 reinstall it before attempting configuration

dpkg: error processing package python3-wheel (--configure):
 package is in a very bad inconsistent state; you should
 reinstall it before attempting configuration

Errors were encountered while processing:
 python3-pip
 python3-setuptools
 python3-wheel

E: Sub-process /usr/bin/dpkg returned an error code (1)

我尝试了几种解决方案,但都没有效果。此外,我试图安装的任何软件都会发生这种情况。

snz8szmq

snz8szmq1#

尝试来自AskUbuntu的答案:https://askubuntu.com/a/170808

将其应用于处于不良状态的包。在您的示例中,为python3-pippython3-setuptoolspython3-wheel

sudo dpkg --remove --force-remove-reinstreq python3-pip python3-setuptools python3-wheel
sudo apt-get install python3-pip python3-setuptools python3-wheel

相关问题