Community
Participate
Working Groups
In N20150324-2000 and I20150324-0800, the AllBrowserTests didn't finish and were killed by a timeout. The test was apparently hanging here: [java] java.lang.Exception: main [java] at org.eclipse.swt.internal.gtk.OS._GTK_TYPE_FIXED(Native Method) [java] at org.eclipse.swt.internal.gtk.OS.GTK_TYPE_FIXED(OS.java:1689) [java] at org.eclipse.swt.widgets.Display.createDisplay(Display.java:967) Extract from http://download.eclipse.org/eclipse/downloads/drops4/I20150324-0800/testresults/consolelogs/linux.gtk.x86_64_8.0_consolelog.txt : java-test: [echo] Running org.eclipse.swt.tests.junit.AllBrowserTests. Result file: /opt/users/hudsonbuild/workspace/ep45I-unit-lin64/workarea/I20150324-0800/eclipse-testing/results/linux.gtk.x86_64_8.0/org.eclipse.swt.tests.junit.AllBrowserTests.xml [echo] timout property: 900000 [...] [java] [java] (process:17655): GLib-GObject-CRITICAL **: gtype.c:2475: initialization assertion failed, use IA__g_type_init() prior to this function [java] [java] (process:17655): GLib-CRITICAL **: g_once_init_leave: assertion `initialization_value != 0' failed [java] [java] (process:17655): GLib-GObject-CRITICAL **: gtype.c:2475: initialization assertion failed, use IA__g_type_init() prior to this function [java] [java] (process:17655): GLib-GObject-CRITICAL **: gtype.c:2475: initialization assertion failed, use IA__g_type_init() prior to this function [java] [java] (process:17655): GLib-GObject-CRITICAL **: gtype.c:2475: initialization assertion failed, use IA__g_type_init() prior to this function [java] [java] (process:17655): GLib-GObject-CRITICAL **: g_type_add_interface_static: assertion `G_TYPE_IS_INSTANTIATABLE (instance_type)' failed [java] [java] (process:17655): GLib-GObject-CRITICAL **: gtype.c:2475: initialization assertion failed, use IA__g_type_init() prior to this function [java] [java] (process:17655): GLib-GObject-CRITICAL **: g_type_add_interface_static: assertion `G_TYPE_IS_INSTANTIATABLE (instance_type)' failed [java] [java] (process:17655): GLib-GObject-CRITICAL **: g_signal_lookup: assertion `G_TYPE_IS_INSTANTIATABLE (itype) || G_TYPE_IS_INTERFACE (itype)' failed [java] Xlib: extension "RANDR" missing on display ":100.0". [java] EclipseTestRunner almost reached timeout '900000'. [...] [java] Thread dump 0 at 2015-03-24 11:11:28 -0400: [...] [java] java.lang.Exception: main [java] at org.eclipse.swt.internal.gtk.OS._GTK_TYPE_FIXED(Native Method) [java] at org.eclipse.swt.internal.gtk.OS.GTK_TYPE_FIXED(OS.java:1689) [java] at org.eclipse.swt.widgets.Display.createDisplay(Display.java:967) [java] at org.eclipse.swt.widgets.Display.create(Display.java:917) [java] at org.eclipse.swt.graphics.Device.<init>(Device.java:156) [java] at org.eclipse.swt.widgets.Display.<init>(Display.java:513) [java] at org.eclipse.swt.widgets.Display.<init>(Display.java:504) [java] at org.eclipse.swt.widgets.Display.getDefault(Display.java:1721) [java] at org.eclipse.swt.widgets.Shell.<init>(Shell.java:264) [java] at org.eclipse.swt.widgets.Shell.<init>(Shell.java:257) [java] at org.eclipse.swt.widgets.Shell.<init>(Shell.java:208) [java] at org.eclipse.swt.widgets.Shell.<init>(Shell.java:144) [java] at org.eclipse.swt.tests.junit.Test_org_eclipse_swt_widgets_Widget.setUp(Test_org_eclipse_swt_widgets_Widget.java:41) [java] at org.eclipse.swt.tests.junit.Test_org_eclipse_swt_widgets_Composite.setUp(Test_org_eclipse_swt_widgets_Composite.java:38) [java] at org.eclipse.swt.tests.junit.Test_org_eclipse_swt_browser_Browser.setUp(Test_org_eclipse_swt_browser_Browser.java:43) [java] at junit.framework.TestCase.runBare(TestCase.java:139) [...] [...] [java] Timeout: killed the sub-process collect-results: [junitreport] the file /opt/users/hudsonbuild/workspace/ep45I-unit-lin64/workarea/I20150324-0800/eclipse-testing/test-eclipse/eclipse/org.eclipse.swt.tests.junit.AllBrowserTests.xml is empty. [junitreport] This can be caused by the test JVM exiting unexpectedly
If you wonder why you didn't see a test failure in the build, see bug 423561 comment 46. It's basically due to bug 210792.
When I try to run AllBrowserTests in my workspace, it hangs already a few lines earlier in OS.gtk_init_check(..): OS._gtk_init_check(int[], int[]) line: not available [native method] OS.gtk_init_check(int[], int[]) line: 8863 Display.createDisplay(DeviceData) line: 932
Is this gtk2/gtk3 specific? I haven't looked into this too deeply. When I run the tests (Gtk2|Gtk3) then they do seem to pass (somewhat slowly, but eventually they pass). Fedora 21. Gtk-3.14/Gtk-2.24 Do the tests actually fail for you?
(In reply to Leo Ufimtsev from comment #3) > Is this gtk2/gtk3 specific? No, comment 2 happens with GTK2 (2.24.10) and GTK3 (3.4.2) on Ubuntu 12.04 32-bit. Running this is enough to reproduce: public static void main(String[] args) { new org.eclipse.swt.widgets.Shell(); } On the Hudson test machine, the GTK version is 2.18.9.
Comment 4 passes locally when I check out I20150320-0030 or the commit before bug 427776 comment 46: http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=e9c202445b7800e816318f00aed3887885c67efd After that commit, it hangs.
Markus, just to be sure - this problem with GTK_TYPE_FIXED happens on both GTK 2 and 3? I ask because GTK_TYPE_FIXED is not called on GTK 3 AFAICS.
(In reply to Alexander Kurtakov from comment #6) > Markus, just to be sure - this problem with GTK_TYPE_FIXED happens on both > GTK 2 and 3? I ask because GTK_TYPE_FIXED is not called on GTK 3 AFAICS. The hang in _GTK_TYPE_FIXED only happens on the test machine, which currently only runs GTK 2. In my workspace, the call to "OS.GTK_TYPE_WIDGET ()" in Control's new static initializer block writes the messages below to stderr. Note that the problem still happens when I call Display.getCurrent() before new Shell(), but it doesn't happen any more when I call Display.getDefault() or new Display(). => Looks like the static initializer just runs too early. (process:6857): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.32.4/./gobject/gtype.c:2722: You forgot to call g_type_init() (process:6857): GLib-CRITICAL **: g_once_init_leave: assertion `result != 0' failed (process:6857): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.32.4/./gobject/gtype.c:2722: You forgot to call g_type_init() (process:6857): GLib-GObject-WARNING **: cannot add class private field to invalid type '<invalid>' (process:6857): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.32.4/./gobject/gtype.c:2722: You forgot to call g_type_init() (process:6857): GLib-GObject-CRITICAL **: g_type_add_interface_static: assertion `G_TYPE_IS_INSTANTIATABLE (instance_type)' failed (process:6857): GLib-GObject-CRITICAL **: /build/buildd/glib2.0-2.32.4/./gobject/gtype.c:2722: You forgot to call g_type_init() (process:6857): GLib-GObject-CRITICAL **: g_type_interface_add_prerequisite: assertion `G_TYPE_IS_INTERFACE (interface_type)' failed (process:6857): GLib-CRITICAL **: g_once_init_leave: assertion `result != 0' failed (process:6857): GLib-GObject-CRITICAL **: g_type_add_interface_static: assertion `G_TYPE_IS_INSTANTIATABLE (instance_type)' failed
I could reproduce this on Ubuntu 12.04. I moved the initialization code to createWidget. I don't know if this could be done earlier but it fixes the problem for me. I also made sure that the crash that this code fixes hasn't come back. https://git.eclipse.org/r/#/c/44711/
(In reply to Marc-Andre Laperle from comment #8) > I could reproduce this on Ubuntu 12.04. I moved the initialization code to > createWidget. I don't know if this could be done earlier but it fixes the > problem for me. I also made sure that the crash that this code fixes hasn't > come back. > > https://git.eclipse.org/r/#/c/44711/ With this patch I get "(process:5556): GLib-GObject-WARNING **: gsignal.c:1189: unable to lookup signal "enter-notify-event" of unloaded type 'GtkWidget' " when rnning AllBrowserTests on console but the tests succeed. Would you please look into fixing it?
Gerrit change https://git.eclipse.org/r/44711 was merged to [master]. Commit: http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=4a52f8150fbdabef3de8fe2008687f7e2f438913
(In reply to Alexander Kurtakov from comment #9) For me, on Ubuntu 12.04, AllBrowserTests also succeeds, but without printing anything to the console (except for the "Browser#setUp():" progress messages).
Markus, Mark-Andre, so this happens on Fedora 22 with GTK 3.16 and GLib 2.44. The fix I think is version guarding the callback creation like the other parts of the patch, it's not used on other versions.
New Gerrit change created: https://git.eclipse.org/r/44861
I would welcome testing for my patch though it's supposed to be straightforward.
New Gerrit change created: https://git.eclipse.org/r/44933
Gerrit change https://git.eclipse.org/r/44933 was merged to [master]. Commit: http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=ac5028d481c4987afadfb0539c67929c92bf84a9
Thanks, Mark-Andre, with your patch warning is gone for me. Pushed to master.
Reopening to address Marc-Andre's comment in https://git.eclipse.org/r/#/c/44933/ > you didn't want us to add the version check here? I left it out to make it easier for you to test. And my comment in https://git.eclipse.org/r/#/c/44861/ > Looks good, but I'd also avoid some code duplication and replace the two old occurrences of > if (OS.GTK3 && OS.GTK_VERSION < OS.VERSION (3, 11, 9)) > with > if (enterNotifyEventFunc != null)
(In reply to Markus Keller from comment #18) > Reopening to address Marc-Andre's comment in > https://git.eclipse.org/r/#/c/44933/ > > you didn't want us to add the version check here? I left it out to make it easier for you to test. > > And my comment in https://git.eclipse.org/r/#/c/44861/ > > > Looks good, but I'd also avoid some code duplication and replace the two old occurrences of > > if (OS.GTK3 && OS.GTK_VERSION < OS.VERSION (3, 11, 9)) > > with > > if (enterNotifyEventFunc != null) Fixed via http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=5b490bb962a97813a4885b327f855701a501fd7e