16.04 LTS,dpkg 无法设置 update-notifier-common

16.04 LTS,dpkg 无法设置 update-notifier-common

当更新运行 dpkg 时我收到以下错误:

Unpacking debconf (1.5.58ubuntu1) over (1.5.58ubuntu1) ...  
Setting up debconf (1.5.58ubuntu1) ...  
Setting up update-notifier-common (3.168.8) ...  
Traceback (most recent call last):  
  File "/usr/lib/update-notifier/package-data-downloader", line 24, in <module>
    import debian.deb822  
  File "/usr/lib/python3/dist-packages/debian/deb822.py", line 47, in <module>
    import six  
ImportError: No module named 'six'  
dpkg: error processing package update-notifier-common (--configure):  
 subprocess installed post-installation script returned error exit status 1  
dpkg: dependency problems prevent configuration of update-notifier:  
 update-notifier depends on update-notifier-common (= 3.168.8); however:  
  Package update-notifier-common is not configured yet.  

dpkg: error processing package update-notifier (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of update-manager:
 update-manager depends on update-notifier; however:
  Package update-notifier is not configured yet.

dpkg: error processing package update-manager (--configure):  
 dependency problems - leaving unconfigured  
dpkg: dependency problems prevent configuration of ubuntu-release-upgrader-gtk:  
 ubuntu-release-upgrader-gtk depends on update-manager; however:  
  Package update-manager is not configured yet.  

dpkg: error processing package ubuntu-release-upgrader-gtk (--configure):  
 dependency problems - leaving unconfigured  
No apport report written because the error message indicates its a followup error from a previous failure.    
                          No apport report written because the error message  
 indicates its a followup error from a previous failure.  
                                                    No apport report written because MaxReports is reached already  
                                  Processing triggers for man-db (2.7.5-1) ...  
Errors were encountered while processing:    
 update-notifier-common   
 update-notifier  
 update-manager  
 ubuntu-release-upgrader-gtk  
E: Sub-process /usr/bin/dpkg returned an error code (1)  

这似乎与 python 有关。我的系统上有 python 3.5 和 3.6.5。

答案1

我已将系统 python3 指向 python3.6,dpkg 错误消失。我对此仍然有点不舒服,但到目前为止,所有依赖于 python3 的代码似乎都运行正常。

相关内容