Python 已安装,但 apt-get 仍然给出依赖性错误

Python 已安装,但 apt-get 仍然给出依赖性错误

我正在使用 Ubuntu 16.04 机器。据我所知,我已经正确安装了最新版本的 Python 2 和 3:

$ python --version
Python 2.7.13

$ python2 --version  
Python 2.7.13  

$ python3 --version  
Python 3.6.2

但是,当我尝试安装依赖于 python 的其他包时,apt-get似乎无法识别 python,因此无法安装依赖于任何与 python 相关的东西的包。

例如,

$ sudo apt-get install python-wxversion

导致:

Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

> The following packages have unmet dependencies:
 python-wxversion : Depends: python:any (< 2.8)
                    Depends: python:any (>= 2.7.5-5~)
E: Unable to correct problems, you have held broken packages.

其他与 Python 相关的安装似乎也会导致类似的问题。有什么建议吗?

sudo apt-get install -f什么也没做。)

相关内容