Comment 8 for bug 913991

Revision history for this message
In , Jason Conti (jconti) wrote :

Barry, comment out the DBUS_FATAL_WARNINGS=1 line in test/run-test.sh. It seems like the tests complete successfully. I think the aborts on ubuntu may be outside the scope of dbus-python, because I can reproduce it using just the TestSuitePythonService.service (with the python code replaced with echo hello as above), tmp-session-bus.conf, the following GDBus code:

#include <gtk/gtk.h>

int main()
{
  gtk_init(NULL, NULL);
  GError *error = NULL;
  GDBusProxy *proxy = g_dbus_proxy_new_for_bus_sync(G_BUS_TYPE_SESSION,
      G_DBUS_PROXY_FLAGS_NONE,
      NULL,
      "org.freedesktop.DBus.TestSuitePythonService",
      "/org/freedesktop/DBus/TestSuitePythonObject",
      "org.freedesktop.DBus.TestSuiteInterface",
      NULL,
      &error);

  if (error != NULL) {
    g_warning("Failed to get proxy: %s", error->message);
    g_error_free(error);
  }

  return 0;
}

and the following bash script:

#!/bin/bash
export DBUS_FATAL_WARNINGS=1

eval $(dbus-launch --sh-syntax --config-file=tmp-session-bus.conf)

echo "Started session bus at $DBUS_SESSION_BUS_PID"

./test-dbus

echo "Killing session bus at $DBUS_SESSION_BUS_PID"
kill $DBUS_SESSION_BUS_PID

Commenting out the export DBUS_FATAL_WARNINGS=1 line allows the code in test-dbus to run until it times out, with the line it aborts immediately just like in the tests.