[英]dpkg: error processing package <package>: package is in a very bad inconsistent state; you should reinstall it before attempting configuration
I'm trying to do:我正在尝试做:
sudo apt-get update && sudo apt-get upgrade
but I'm getting the following error:但我收到以下错误:
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)
I tried several solutions found but nothing helped.我尝试了几种解决方案,但没有任何帮助。 Also, it is happening with any software I try to install.
此外,我尝试安装的任何软件都会发生这种情况。
Try this answer from AskUbuntu: https://askubuntu.com/a/170808 .试试 AskUbuntu 的这个答案: https://askubuntu.com/a/170808 。
Apply it to the packages that are in a bad state.将其应用于坏 state 中的包。 In your case,
python3-pip
, python3-setuptools
, and python3-wheel
:在您的情况下,
python3-pip
、 python3-setuptools
和python3-wheel
:
sudo dpkg --remove --force-remove-reinstreq python3-pip python3-setuptools python3-wheel
sudo apt-get install python3-pip python3-setuptools python3-wheel
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.