connlim / pe

0 stars 0 forks source link

Unable to launch on Wayland on Linux #2

Open connlim opened 1 year ago

connlim commented 1 year ago

When running in a Wayland environment on Linux (Fedora 36 distro) the app does not start. The bug is due to a bug in the default JavaFX version that makes it crash on Wayland. App works when forcing desktop environment to X11.

Logs

Error message

(java:1160936): Gdk-CRITICAL **: 16:12:16.566: gdk_x11_display_set_window_scale: assertion 'GDK_IS_X11_DISPLAY (display)' failed

(java:1160936): GLib-GObject-WARNING **: 16:12:16.566: invalid cast from 'GdkWaylandDisplay' to 'GdkX11Display'

System Info

$ gnome-shell --version
GNOME Shell 42.6

$ uname -a
Linux rome 6.0.5-200.fc36.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Oct 26 15:55:21 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

$ cat /etc/os-release
NAME="Fedora Linux"
VERSION="36 (Workstation Edition)"
ID=fedora
VERSION_ID=36
VERSION_CODENAME=""
PLATFORM_ID="platform:f36"
PRETTY_NAME="Fedora Linux 36 (Workstation Edition)"
ANSI_COLOR="0;38;2;60;110;180"
LOGO=fedora-logo-icon
CPE_NAME="cpe:/o:fedoraproject:fedora:36"
HOME_URL="https://fedoraproject.org/"
DOCUMENTATION_URL="https://docs.fedoraproject.org/en-US/fedora/f36/system-administrators-guide/"
SUPPORT_URL="https://ask.fedoraproject.org/"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_BUGZILLA_PRODUCT="Fedora"
REDHAT_BUGZILLA_PRODUCT_VERSION=36
REDHAT_SUPPORT_PRODUCT="Fedora"
REDHAT_SUPPORT_PRODUCT_VERSION=36
PRIVACY_POLICY_URL="https://fedoraproject.org/wiki/Legal:PrivacyPolicy"
VARIANT="Workstation Edition"
VARIANT_ID=workstation
nus-se-script commented 1 year ago

Team's Response

The application can still run in sudo-mode as shown in the screenshot below. Hence, the impact to the user is low as the OS is not a mainstream OS and people on the OS can still run the application.

image.png

Items for the Tester to Verify

:question: Issue severity

Team chose [severity.Low] Originally [severity.High]

Reason for disagreement: Running an app with sudo is unsafe and should never be done unless it is explicitly required (which it is not in this case). And the reason sudo works is that the root user has no wayland display. A regular user without sudo permissions would not be able to use the app.

Wayland is a display server protocol used in all modern Linux distros, including Ubuntu, the most popular distro. As the issue is caused by Wayland and not my specific distro, this issue would happen on many modern Linux systems. Many people on Linux will not be able to run the application because of this.

This is also a known issue on the forum: https://github.com/nus-cs2103-AY2223S1/forum/issues/246. The fix is simple and would've been caught with a smoke test on Linux, as many others groups have done. It is not acceptable to not support mainstream Linux distros as that is what the requirements are.