Activity log for bug #1775587

Date Who What changed Old value New value Message
2018-06-07 11:33:24 Alejandro Perez bug added bug
2018-06-07 11:37:36 Alejandro Perez attachment added Add an additional error code https://bugs.launchpad.net/moonshot-ui/+bug/1775587/+attachment/5149741/+files/dbuserror.patch
2018-06-07 11:38:24 Alejandro Perez description It seems that packages for version 1.0.5 where built with IPC_DBUS_GLIB, which uses a simplified code for launching the ephemeral DBUS session, whereas packages for version 1.0.6 are built with IPC_DBUS_GLIB disabled. While this works ok for Centos 7 and Debian, in Centos 6.9 the attempt to connect to the current DBUS session (which does not exist) does not result into DBUS_GERROR_NOT_SUPPORTED, but into DBUS_GERROR_SPAWN_EXEC_FAILED. This makes that dbus_launch_moonshot is not executed hence no DBUS session is available for the client and it fails. A simple patch that works is including this second error into the known errors that can trigger the execution of dbus_launch_moonshot(). diff --git a/libmoonshot/libmoonshot-dbus.c b/libmoonshot/libmoonshot-dbus.c index f3635bb..6a753e3 100644 --- a/libmoonshot/libmoonshot-dbus.c +++ b/libmoonshot/libmoonshot-dbus.c @@ -167,7 +167,8 @@ static DBusGProxy *dbus_connect (MoonshotError **error, GPid *server_pid) { connection = dbus_g_bus_get (DBUS_BUS_SESSION, &g_error); - if (g_error_matches(g_error, DBUS_GERROR, DBUS_GERROR_NOT_SUPPORTED)) { + if (g_error_matches(g_error, DBUS_GERROR, DBUS_GERROR_NOT_SUPPORTED) || + g_error_matches(g_error, DBUS_GERROR, DBUS_GERROR_SPAWN_EXEC_FAILED)) { /*Generally this means autolaunch failed because probably DISPLAY is unset*/ connection = dbus_launch_moonshot(); ad_hoc_dbus_session = TRUE; It seems that packages for version 1.0.5 where built with IPC_DBUS_GLIB, which uses a simplified code for launching the ephemeral DBUS session, whereas packages for version 1.0.6 are built with IPC_DBUS_GLIB disabled. While this works ok for Centos 7 and Debian, in Centos 6.9 the attempt to connect to the current DBUS session (which does not exist) does not result into DBUS_GERROR_NOT_SUPPORTED, but into DBUS_GERROR_SPAWN_EXEC_FAILED. This makes that dbus_launch_moonshot is not executed hence no DBUS session is available for the client and it fails. A simple patch that works is including this second error into the known errors that can trigger the execution of dbus_launch_moonshot(). EDITED: removed pasted patch and attach it properly.
2018-06-07 15:54:21 Jennifer Richards moonshot-ui: status New Confirmed
2018-06-07 15:55:10 Jennifer Richards moonshot-ui: status Confirmed In Progress
2018-06-07 15:55:13 Jennifer Richards moonshot-ui: assignee Jennifer Richards (jennifer-k)
2018-06-07 15:55:17 Jennifer Richards moonshot-ui: importance Undecided Medium
2018-06-07 16:17:02 Jennifer Richards moonshot-ui: status In Progress Fix Committed