Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Constant crashes when attempting to draw on canvas on new gtk4.14 ngl renderer #1061

Open
fotnite-vevo opened this issue Mar 29, 2024 · 10 comments
Labels
bug Something isn't working crash Causes a crash gtk4 Related to Gtk4

Comments

@fotnite-vevo
Copy link

fotnite-vevo commented Mar 29, 2024

Describe the bug
Nearly any action (attempting to draw on the canvas, attempting to move copied in photo) will potentially crash the app, and occasionally crash the entire desktop. Only occurs when running app under Wayland (never crashes under XWayland). Has only been happening since recent upgrade to GNOME 46, most recent rnote version did not have this issue prior.

To Reproduce
Steps to reproduce the behavior:

  1. Attempt to draw on canvas, attempt to move object, etc.

Expected behavior
Rnote doesn't crash

Console Output

2024-03-29T23:05:52.845016Z DEBUG rnote: .. tracing subscriber initialized.
rnote: ../cairo/src/cairo-pattern.c:3831: _cairo_pattern_get_extents: Assertion `status == CAIRO_STATUS_SUCCESS' failed.
fish: Job 1, 'RUST_LOG=rnote=debug RUST_BACKT…' terminated by signal SIGABRT (Abort)

Desktop (please complete the following information):

  • OS: Arch Linux
  • App Version: Rnote v0.10.1 (also applies to previous versions, tested v0.9.4)
  • Installation Source: Arch Linux Community
  • Desktop Environment: GNOME 46.0
  • Display Server: Wayland
  • Input Source: Mouse and Keyboard, Tablet
@fotnite-vevo fotnite-vevo changed the title Constant crashes when attempting to draw on canvas since upgrade to GNOME 45 Constant crashes when attempting to draw on canvas since upgrade to GNOME 46 Mar 29, 2024
@fotnite-vevo
Copy link
Author

Alright, I did a bit more testing, and it seems to be related to fractional scaling. I usually have fractional scaling set to 1.25x, I still get crashes on 1.5x, but not on 1x, 1.75x, or 2x. but Not sure if it's an upstream bug or not but it seems like it might be.

@Doublonmousse
Copy link
Contributor

Gnome 46 means running on newer gtk (4.14) and libadwaita (1.5) versions.

gtk 4.14 made ngl the default renderer and that seems like the most likely suspect (see https://gitlab.gnome.org/GNOME/gtk/-/issues/?sort=created_date&state=opened&search=ngl&first_page_size=20)

Maybe follow https://gitlab.gnome.org/GNOME/gtk/-/issues/6574#note_2063669 and set GSK_RENDERER=gl or to another renderer to test if ngl is the issue (and report issues upstream to the gtk gitlab).

It will be a while before we can seriously look at gtk 4.14 though (probably need to wait until the new versions are available on all platforms

  • mac : brew, up to date
  • windows : msys, not up to date but seems close
  • linux : I'm not sure flatpak runtimes are up to date, debian packages are not on gtk 4.14, and for fedora/ubuntu-based things the latest versions will probably come not sooner than the next release (fedora 40 and next ubuntu lts)

Once this is available we'll be able to look at gtk 4.14 and related issues (and look back on any previous gtk issues and workarounds)

@fotnite-vevo
Copy link
Author

fotnite-vevo commented Mar 31, 2024

gtk 4.14 made ngl the default renderer and that seems like the most likely suspect (see https://gitlab.gnome.org/GNOME/gtk/-/issues/?sort=created_date&state=opened&search=ngl&first_page_size=20)

Yes, it seems like this is the source of the issue. I'll report this upstream when I have the time to do so.

@flxzt flxzt added bug Something isn't working gtk4 Related to Gtk4 labels Mar 31, 2024
@flxzt flxzt changed the title Constant crashes when attempting to draw on canvas since upgrade to GNOME 46 Constant crashes when attempting to draw on canvas on new gtk4.14 ngl renderer Mar 31, 2024
@flxzt flxzt added the crash Causes a crash label Mar 31, 2024
@UnlimitedKaos
Copy link

Maybe follow [..] and set GSK_RENDERER=gl

I also experienced crashes with the arch community package (fwiw Im using Plasma6/Wayland), and this seems to fix it

@safizn
Copy link

safizn commented Apr 18, 2024

Experiencing crashes too when drawing. Probably related to fractional scaling as mentioned above.

Crashing version:

   Commit: 25f606dcb4150523065a0167c44f074b31288ae0f40d2cc538c5ecd6c3b7f6c8
   Parent: eeb5736a683913857b95ea5fd2dcd8f4cae1acd65aa375cc879623958c9ce9e4
   Subject: update to v0.10.2 (#54) (5f9c3581)
   Date: 2024-04-06 13:24:35 +0000

Passing version (didn't test versions in-between): This version does not exhibit the crashing issue.

    Commit: dc829353acef99cde736910ca4bafcf6ed4ecdb9623056b0d48e043ef7c4254e
    Subject: update to `v0.9.4` (#48) (ea975b81)
    Date: 2023-12-13 08:51:52 +0000

For anyone looking for a quick fix, install the version that works:

flatpak remote-info --log flathub com.github.flxzt.rnote
flatpak update --commit=dc829353acef99cde736910ca4bafcf6ed4ecdb9623056b0d48e043ef7c4254e com.github.flxzt.rnote

@danielwmoore
Copy link

A little extra info, in case it helps.

I'm not using fractional scaling, but am running Ubuntu 24.04 with Gnome 46, and experience the same crashes. Drawing then attempting to zoom or pan often crashes. Drawing and switching to eraser crashes. Takes the entire desktop with it and I have to log back in, having lost any unsaved work in all my apps.

Having the same issue with GIMP crashing when I switch from mouse input to pen input, didn't happen before moving to 24.04 with Gnome 46, so probably the new renderer for sure.

I have not had any crashes with Xournal++ using the pen. rnote and GIMP crash regularly when using the pen. I know, these apps aren't rnote, but I thought it might help in hammering down exactly where the issue is.

@Doomsdayrs
Copy link

Doomsdayrs commented Apr 25, 2024

Adding a bit more info.

This issue will eventually cause the entire gnome-shell to crash as well.

https://retrace.fedoraproject.org/faf/reports/939439/

@mbeps
Copy link

mbeps commented Apr 26, 2024

Hello,
I also have the same issue. Sometimes the entire app crashes but in more sever cases, the entire Gnome Shell crashes. I am currently on Gnome 46 on Fedora 40 using Wayland. The stylus is some sort of Wacom solution used by Dell.

flatpak run com.github.flxzt.rnote
rnote: ../src/cairo-pattern.c:3831: _cairo_pattern_get_extents: Assertion `status == CAIRO_STATUS_SUCCESS' failed.

@fotnite-vevo
Copy link
Author

A bit more probing found that this issue does not occur for the Brush tool when path modelling is set to simple. Dragging images can still cause crashes.

@fotnite-vevo
Copy link
Author

fotnite-vevo commented May 9, 2024

Hello, I also have the same issue. Sometimes the entire app crashes but in more sever cases, the entire Gnome Shell crashes. I am currently on Gnome 46 on Fedora 40 using Wayland. The stylus is some sort of Wacom solution used by Dell.

flatpak run com.github.flxzt.rnote
rnote: ../src/cairo-pattern.c:3831: _cairo_pattern_get_extents: Assertion `status == CAIRO_STATUS_SUCCESS' failed.

Since you're running the flatpak version, your shell crashes are likely caused by this separate bug in Mutter, which has already been patched upstream but has not yet shipped to distributions.

@flxzt flxzt mentioned this issue May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working crash Causes a crash gtk4 Related to Gtk4
Projects
None yet
Development

No branches or pull requests

8 participants