缺少必需的依赖项:python3-dbus [如何安装 python 依赖项]

Gig*_*iux 7 dbus hplip python3

我正在尝试将 HPLIP 3.14.3 更新到 3.15,但无法通过软件中心获得,因此我从这里安装它。

但是,由于python,我在自动安装时遇到了困难。特别是在选择 ubuntu 14.04 后,出现错误:

warning: Missing REQUIRED dependency: python3-dbus (Python DBus - Python bindings for DBus) 
warning: This installer cannot install 'python3-dbus' for your distro/OS and/or version. 
Run Code Online (Sandbox Code Playgroud)

但我已经安装了以下内容:

python
IDLE python 3.4
python 3.4
python3-dbus 1.2.0-2build2 (but not D-bus support & debug)
Run Code Online (Sandbox Code Playgroud)

当我尝试更新这些选项时,我得到了:

Requires installation of untrusted packages
Run Code Online (Sandbox Code Playgroud)

我怎样才能克服这个问题?谢谢

此致

吉久

小智 3

我看到了同样的错误消息,结果发现自定义 Python 安装处于活动状态(使用 virtualenv)。

apt-get install将这些软件包安装到系统的 Python 安装中,但 HPLIP 在另一个 Python 安装处于活动状态的 shell 中运行。您可以通过尝试在 Python 中导入 dbus 来检查这一点,并在与 HPLIP 相同的 shell 中执行:

$ python
Python 3.4.0 (default, Nov 21 2015, 10:48:18) 
[GCC 4.8.4] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import dbus
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named 'dbus'

$ which python
/home/me/custom/python/dir
Run Code Online (Sandbox Code Playgroud)


小智 2

我在使用较新的 HP 打印机和 HPLIP 时也遇到过同样的问题。最终对我有用的是 CUPS 的更新版本。当时,我必须手动编译,但它可能会在最新的测试版(15.04)中更新。毫无疑问,我不建议立即升级...首先尝试实时夜间版本,看看它是否有效。