Flatpak 48.0 crashes every time after successful backup with restic

this is on flatpak 48.0 on fedora 41 using cinnamon. it crashes after backup without any output in the terminal. i just get a notification saying that deja-dup killed by SIGSEGV

Yikes, OK. I will try to reproduce your setup and see if I can crash it too. This sounds reliable for you?

Can you try running it with DEJA_DUP_DEBUG=1 - that should produce more terminal output.

Thank you for reporting this! :pray:

Is there anything interesting about the folders/files you’re backing up, or the storage location for the backup?

Running the following tool (317) command: restic '--json' '--cleanup-cache' '--cache-dir=/home/rory/.var/app/org.gnome.DejaDup/cache/deja-dup/restic' '--option=rclone.program=rclone' '--repo=rclone::drive:acer' 'check' '--with-cache'
TOOL: create exclusive lock for repository
TOOL: load indexes
TOOL: check all packs
TOOL: check snapshots, trees and blobs
TOOL: [0:00] 100.00%  5 / 5 snapshots
TOOL: no errors were found
[rory@acer ~]$

it doesnt seem to spit out anything useful with debug, but it still sends me a notification of a SIGSEVG in gnome-abrt after the backup is successful. this is happening every time. thanks for looking into it

i’m backing up to google drive. nothing unusual that i can think of

OK well good news is that that output indicates to me that we’re fully finishing the backup and the repo looks fine. After each backup, we run a quick ā€œrestic checkā€ command to confirm the repository is alright. It shows five snapshots in your output.

Seems fine. Does the restore pane work alright?

So something after the backup finishes causes a crash…

If you have Deja Dup open while this is happening, can you see if the backup window changes text right before the crash or closes or anything? Just trying to grasp at any clues here :smile:

the last thing i see in the gui is ā€œverifying backupā€ and then it dies. the restore panel works fine and i’ve successfully restored a file to test it

1 Like

OK good to hear. So things are mostly working, with one big exception :smiley:

In trying to reproduce myself in a VM, I haven’t reproduced an after-backup crash. But I did find that if I was in an X11 session (GNOME or Cinnamon), Deja Dup wouldn’t start up. I’d get:

(org.gnome.DejaDup:2): Gdk-WARNING **: 13:00:38.839: The program 'org.gnome.DejaDup' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadRegion (invalid Region parameter)'.
  (Details: serial 615 error_code 140 request_code 138 (XFIXES) minor_code 11)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the GDK_SYNCHRONIZE environment
   variable to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)

Which is worth looking into… Might just be VM oddities, but I’ll look at it. But may not be your thing, since I’d think you’d have a similar print out in your terminal.

But it makes me wonder - are you in X11 or Wayland?

i’m using X11 cinnamon spin 6.4.8

1 Like

Hmm, my X11 crash (which I don’t even know if it’s the same root cause as your issue) went away after I re-built the flatpak with GNOME SDK 47 (instead of the recently released 48). Wondering if there’s some gtk4 bug floating in there.

I was able to launch and back up without incident. I’ve got two proposals for you to try, of varying complexity:

  • Run in a Cinnamon wayland session and try a backup there
  • Re-build Deja Dup with the 47 sdk yourself and see if that works any better for you. This is a bit more involved, and I get it if it’s too much right now. I’ll keep investigating regardless.
flatpak uninstall org.gnome.DejaDup
git clone https://github.com/flathub/org.gnome.DejaDup/ deja-dup-flathub
cd deja-dup-flathub
flatpak install org.gnome.Platform//47 org.gnome.Sdk//47 org.flatpak.Builder
sed -i 's/"48"/"47"/' org.gnome.DejaDup.json
make
flatpak run org.gnome.DejaDup

Another thing that fixed my X11 error:

GSK_RENDERER=ngl flatpak run org.gnome.DejaDup

(GSK_RENDERER=vulkan does have my X11 crash)

it did work under wayland, no crash in deja, but wayland is very experimental for cinnamon, so i cant use it as a daily driver. i wasnt able to rebuild deja because of this:

[rory@acer deja-dup-flathub]$ flatpak install org.flatpak.Builder
Looking for matches…
Skipping: org.flatpak.Builder/x86_64/stable is already installed
[rory@acer deja-dup-flathub]$ make
flatpak-builder --install \
                --user \
                --force-clean \
                _build \
                org.gnome.DejaDup.json
make: flatpak-builder: No such file or directory
make: *** [Makefile:8: flatpak] Error 127
[rory@acer deja-dup-flathub]$

GSK_RENDERER=ngl did not fix my issue on X11

Oh OK good… the wayland test is huge - but yeah I get why you wouldn’t want to live there right now.

OK. So this seems like a gtk/x11 interaction for sure then. Maybe out of my control.

But I would like to nail down if the 47 SDK would work. Because one possible fix here is that I can switch back to 47 for a couple months until whatever bug this is gets fixed. I’m not sure how to report it really, but hopefully we’re not the only people seeing it.

Your build failure make: flatpak-builder: No such file or directory – I forgot one instruction. You’ll need to also run sudo dnf install flatpak-builder

Could you try that and run make again? Thank you for your persistent testing :pray:

building from your instructions works! it’s not crashing anymore

My issue looks like gtk 4.17 should not fall back to Vulkan for X11 (#7346) Ā· Issues Ā· GNOME / gtk Ā· GitLab

Your issue has different symptoms but seems related to rendering issues, so may be same root cause.

Looks like the gtk maintainers are hoping this is not a big problem anymore since it’s been fixed elsewhere in the stack (and those patches went out to Fedora 42 btw - is that an option for ya? I haven’t tested F42 to see if it fixes my crash yet, but that sounds hopeful.)

Doesn’t help flatpak users on older releases, but sounds like there are fixes floating out there.

i just did a clean install of fedora 42 and deja from flathub wont start

rory@fedora:~$ flatpak run org.gnome.DejaDup

(org.gnome.DejaDup:2): Gdk-WARNING **: 18:34:01.030: The program ā€˜org.gnome.DejaDup’ received an X Window System error.
This probably reflects a bug in the program.
The error was ā€˜BadRegion (invalid Region parameter)’.
(Details: serial 689 error_code 140 request_code 138 (XFIXES) minor_code 11)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the GDK_SYNCHRONIZE environment
variable to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)
rory@fedora:~$

however, using your instructions to build with sdk 47 works fine on fedora 42 and no longer crashes. hope this helps!