当我运行 $tryton 时,它对 $ gnuhealth-client 显示相同
$尝试顿
Traceback (most recent call last):
File "/usr/local/bin/tryton", line 52, in <module>
from tryton.client import main
File "/home/gnuhealth/.local/lib/python3.6/site-packages/tryton/client.py", li ne 12, in <module>
from tryton import gui
File "/home/gnuhealth/.local/lib/python3.6/site-packages/tryton/gui/__init__.p y", line 3, in <module>
from .main import *
File "/home/gnuhealth/.local/lib/python3.6/site-packages/tryton/gui/main.py", line 33, in <module>
from tryton.gui.window.activity import Activity
File "/home/gnuhealth/.local/lib/python3.6/site-packages/tryton/gui/window/act ivity.py", line 23, in <module>
class Activity():
File "/home/gnuhealth/.local/lib/python3.6/site-packages/tryton/gui/window/act ivity.py", line 25, in Activity
activity_window = Gtk.Window()
File "/home/gnuhealth/.local/lib/python3.6/site-packages/gi/overrides/Gtk.py", line 521, in __init__
"Gtk couldn't be initialized. "
RuntimeError: Gtk couldn't be initialized. Use Gtk.init_check() if you want to h andle this case.
我该怎么办?
这是检查初始化的输出
gnuhealth@ghealth:~ $ python -c 'from gi.repository import Gtk' -c:1: PyGIWarning: Gtk 在没有指定版本的情况下被导入。在导入之前使用 gi.require_version('Gtk', '3.0') 以确保加载正确的版本。gnuhealth@ghealth:~ $ Gtk.init_check()
^C