每当我运行命令时,我都会遇到 GTK 问题,tryton
或者gnuhealth-client
,我会收到有关 GTK 问题的错误消息:
$tryton
(tryton:1754): Gtk-ERROR **: 12:53:39.748: Can't create a GtkStyleContext without a display connection Trappe pour point d'arrêt et de trace 我能做什么?
$ gnuhealth-client
Traceback(最近一次调用最后):文件“/home/gnuhealth/.local/bin/gnuhealth-client”,第 34 行,从 tryton.client 导入主文件“/home/gnuhealth/.local/lib/python3.6 /site-packages/tryton/client.py”,第 12 行,从 tryton 导入 gui 文件“ /home/gnuhealth/.local/lib/python3.6/site-packages/tryton/gui/init.py”,第 3 行,来自 .main 导入 * 文件“/home/gnuhealth/.local/lib/python3.6/site-packages/tryton/gui/main.py”,第 33 行,来自 tryton.gui .window.activity 导入活动文件“/home/gnuhealth/.local/lib/python3.6/site-packages/tryton/gui/window/activity.py”,第 23 行,在类 Activity():文件“/home /gnuhealth/.local/lib/python3.6/site-packages/tryton/gui/window/activity.py”,第 25 行,在 Activity activity_window = Gtk.Window() 文件“/home/gnuhealth/.local/lib /python3.6/site-packages/gi/overrides/Gtk.py”,第 521 行,init “Gtk 无法初始化。" RuntimeError: Gtk 无法初始化。如果你想处理这种情况,请使用 Gtk.init_check()。