spring-tools: Eclipse crashes after upgrade of libwebkit2gtk to 2.44.x

Version 2.44.0 of the lib gets shipped with the upgrade to Gnome 46 (more or less, maybe not a direct dependency). This already happened on Arch, so it will be soon widespread on other distros. Eclipse (and as a consequence STS) hangs then dump often, specifically when a popup is triggered by hovering on some elements and alike. This is the typical hs_err_pidXXX.log confirming the issue after crash

---------------  T H R E A D  ---------------

Current thread (0x000070cae0027180):  JavaThread "main" [_thread_in_native, id=2169, stack(0x000070cae7614000,0x000070cae7714000)]

Stack: [0x000070cae7614000,0x000070cae7714000],  sp=0x000070cae7710ef0,  free space=1011k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [libwebkit2gtk-4.1.so.0+0x10c690b]

The issue seems to be related to hardware acceleration in Wayland, so a suggested workaround is to use X server emulation, launching STS with

GDK_BACKEND=x11 STS

I can confirm it works, and that issue is still present in libwebkit2gtk 2.44.1 released a couple days ago. The problem is tracked down upstream by Eclipse devs, but unfortunately it looks like a really old ghost-bug not even Gnome devs have been able to solve in years, so they decided to follow the same path of some official Gnome packages disabling hardware acceleration. This is the fix pushed upstream https://github.com/eclipse-platform/eclipse.platform.swt/commit/d76f1472ed73a04b74b25b5b54a408666bf37162

I’d suggest to realease a STS version based on a build including the fix. Maybe latest milestone one? https://github.com/eclipse-platform/eclipse.platform.swt/releases/tag/S4_32_0_M1

Cheers

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 1
  • Comments: 24 (7 by maintainers)

Most upvoted comments

Yes, same issue. I’ll report it that in upstream tracker.

Just remember that what made the difference for me, was the upgrade of wayland to 4.23.0. It landed in official repo for Arch Linux, can’t say for other distros.

@4javier Thanks for the update on this. With that, I will go ahead and close this issue as fixed. Would be great if people observing this issue could give the latest nightly builds on Eclipse 4.32 a try: https://cdn.spring.io/spring-tools/snapshot/STS4/nightly-distributions.html. That will turn into the next Spring Tools 4.23.0 release next week.

Just try the X11 backend GDK_BACKEND=x11 STS

That was the first thing I tried. I can successfully open the market place. Sorry to hear, Mike 😦.

Previously I also set GTK_IM_MODULE=ibus, but I’m not sure this is required anymore for Eclipse (https://github.com/eclipse-platform/eclipse.platform.swt/issues/270). It’s a different problem, but I still have this variable set.

Regards Andreas

I’m using wayland and WEBKIT_DISABLE_COMPOSITING_MODE=1 fixed it for me (sts 4.22.1.RELEASE, java 21, Ubuntu 23.10).

This works for me, I’m using Fedora 39 Gnome, sts 4.22.1.RELEASE, java 17.

Nevermind, crash when I open the marketplace windows

I’m using wayland and WEBKIT_DISABLE_COMPOSITING_MODE=1 fixed it for me (sts 4.22.1.RELEASE, java 21, Ubuntu 23.10).

P.S.: there’s a typo in the download page, the last nightly is 2024-06, not 2023

Thanks for pointing that out, fixed with https://github.com/spring-projects/sts4/commit/1d927b70419de1b67e99869779f3daee4dd8676f (might take a little while until it promotes to the page)

@tntra-dhananjay The mentioned workaround works for you as well?

@martinlippert - following solution worked for me

Added WEBKIT_DISABLE_COMPOSITING_MODE=1 in Exec Exec=env WEBKIT_DISABLE_COMPOSITING_MODE=1 ./sts-4.22.0/SpringToolSuite4 --limit-modules %f