kuthulux / gnome-connection-manager

repository for gnome-connection-manager from kuthulu.com/gcm
Other
68 stars 28 forks source link

Broken since updated to ubuntu 20.10 #49

Closed miberecz closed 3 years ago

miberecz commented 3 years ago

Since I updated to the newest Ubuntu, its not working. Its starts but neither local or ssh terminals are working.

mqmq0@mqmq0:/usr/share/gnome-connection-manager$ ./gnome_connection_manager.py 
./gnome_connection_manager.py:1621: DeprecationWarning: Gtk.StyleContext.get_background_color is deprecated
  rgba = self.treeServers.get_style_context().get_background_color(Gtk.StateFlags.NORMAL)
./gnome_connection_manager.py:957: DeprecationWarning: Gtk.ImageMenuItem.set_image is deprecated
  menuItem.set_image(Gtk.Image.new_from_icon_name(Gtk.STOCK_COPY, Gtk.IconSize.MENU))
./gnome_connection_manager.py:566: DeprecationWarning: Gtk.Widget.override_color is deprecated
  self.get_widget('txtSearch').override_color(Gtk.StateFlags.NORMAL, parse_color_rgba('darkgray'))

(gnome_connection_manager.py:6283): VTE-CRITICAL **: 21:10:36.929: void vte_terminal_spawn_with_fds_async(VteTerminal*, VtePtyFlags, const char*, const char* const*, const char* const*, const int*, int, const int*, int, GSpawnFlags, GSpawnChildSetupFunc, gpointer, GDestroyNotify, int, GCancellable*, VteTerminalSpawnAsyncCallback, gpointer): assertion 'callback' failed

Screenshot from 2020-10-28 21-20-02

Is there anything I can do to fix this?

pstast commented 3 years ago

I can confirm the same problem after installing GCM in Ubuntu 20.10.

@mqmq0 Any idea how to fix that?

miberecz commented 3 years ago

I couldnt find any so far

On Thu, Jan 7, 2021 at 11:48 PM Petr Šťastný notifications@github.com wrote:

I can confirm the same problem after installing GCM in Ubuntu 20.10.

@mqmq0 https://github.com/mqmq0 Any idea how to fix that?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/kuthulux/gnome-connection-manager/issues/49#issuecomment-756434019, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADFAVC6DPUCHLCWIV4F2Q4DSYY24BANCNFSM4TC2SYPQ .

kuthulux commented 3 years ago

Hi there Looks like the api call for spawning a process has changed in 20.10, a momentarily fix is passing two extra arguments to method spawn_async (line 500)

if TERMINAL_V048:
    terminal.spawn_async(Vte.PtyFlags.DEFAULT,
                       os.getenv("HOME"),
                       args,
                       envv,
                       flag_spawn | GLib.SpawnFlags.DO_NOT_REAP_CHILD |

GLib.SpawnFlags.SEARCH_PATH, None, None, -1, None, lambda term,pid,err,user_data: None, None )

it should work, however a warning is logged in the console. I'll have to take a deeper look at the api docs to propose a proper fix that will work in 20.04 and 20.10

kuthulux commented 3 years ago

to fix the warning, the flag GLib.SpawnFlags.DO_NOT_REAP_CHILD has to be deleted

    if TERMINAL_V048:
        terminal.spawn_async(Vte.PtyFlags.DEFAULT,
                           os.getenv("HOME"),
                           args,
                           envv,
                           flag_spawn | GLib.SpawnFlags.SEARCH_PATH,
                           None,
                           None,
                           -1,
                           None,
                           lambda term,pid,err,user_data: None,
                           None
                           )
pstast commented 3 years ago

I confirm this fix works for me on Ubuntu 20.10. Thanks!