Gnome-terminal not starting due to error in python script related to GI

前端 未结 5 2106
春和景丽
春和景丽 2021-01-02 07:13

When I run gnome-terminal, I get the following error:

Traceback (most recent call last):
  File \"/usr/bin/gnome-terminal\", line 9, in 
    fr         


        
5条回答
  •  情书的邮戳
    2021-01-02 07:36

    Happened to me with /usr/bin/chrome-gnome-shell script, on Linux (RHEL 7.6):

    Traceback (most recent call last):
    Traceback (most recent call last):
      File "/usr/bin/chrome-gnome-shell", line 16, in 
        from gi.repository import GLib, Gio
    ModuleNotFoundError: No module named 'gi'
    

    To fix it I had to install PyGObject:

    $ sudo yum install python36-gobject.x86_64
    # or directly with pip: pip3 install PyGObject
    

    Once completed installation, running the script showed no error.

提交回复
热议问题