当我试图运行时,这个问题就开始了redshift-gtk
。我手动安装了程序,它通过 just 运行良好redshift
,但我希望它与指示器一起运行。我总是得到以下输出:
Traceback (most recent call last):
File "/usr/local/bin/redshift-gtk", line 26, in <module>
from redshift_gtk.statusicon import run
File "/usr/local/lib/python3.8/site-packages/redshift_gtk/statusicon.py", line 30, in <module>
import gi
ModuleNotFoundError: No module named 'gi'
我确实认为这更像是一个普遍问题,而不是特定于红移的问题。我已经安装了必要的先决条件:
python3-gi is already the newest version (3.36.0-1)
python3-gi-cairo is already the newest version (3.36.0-1).
gir1.2-gtk-3.0 is already the newest version (3.24.20-0ubuntu1)
我试过执行locate python3-gi
,结果如下:
/snap/gnome-3-28-1804/128/usr/share/doc/python3-gi
/snap/gnome-3-28-1804/128/usr/share/doc/python3-gi-cairo
/snap/gnome-3-28-1804/128/usr/share/doc/python3-gi/changelog.Debian.gz
/snap/gnome-3-28-1804/128/usr/share/doc/python3-gi/copyright
/snap/gnome-3-28-1804/128/usr/share/doc/python3-gi-cairo/copyright
/usr/share/doc/python3-gi
/usr/share/doc/python3-gi-cairo
/usr/share/doc/python3-gi/changelog.Debian.gz
/usr/share/doc/python3-gi/copyright
/usr/share/doc/python3-gi-cairo/changelog.Debian.gz
/usr/share/doc/python3-gi-cairo/copyright
/var/lib/dpkg/info/python3-gi-cairo.list
/var/lib/dpkg/info/python3-gi-cairo.md5sums
/var/lib/dpkg/info/python3-gi.list
/var/lib/dpkg/info/python3-gi.md5sums
/var/lib/dpkg/info/python3-gi.postinst
/var/lib/dpkg/info/python3-gi.prerm
所以我不知道为什么我有一个“没有名为'gi'的模块”错误。我还安装了 python-gobject:
python-gobject is already the newest version (3.34.0+2.28.6-14ubuntu1)
这是我当前的linux版本:
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.1 LTS
Release: 20.04
Codename: focal
这里有什么问题?
首先您应该知道 RedShift 已打包在所有 Ubuntu 版本中。
要删除本地安装的东西,请使用:
因此,您可以简单地从存储库安装 RedShift: