flatpak firefox (and forks like librewolf) "break" after long periods of inactivity or DPMS
I'm not exactly sure what causes this, but it's one of the following:
- Long periods of inactivity (multiple hours)
- Locking with swaylock (either manual or automatically from idling)
- DPMS (with swaylock)
How firefox and forks like librewolf break is they eventually just stop loading new tabs (the tab never loads and stays blank, not even the home page appears), if existing tabs are reloaded they either don't reload at all or blank, and prevent more windows of the browser from being opened until the process is killed then re-opened. So far, I've produced this Firefox (flatpak), Librewolf (flatpak), Zen (flatpak). If it matters, I usually have around 4-5 windows of librewolf opened with my tabs seperated between them by genre.
This bug has existed for a while and seem to have forgotten to report it until now. I usually run into this multiple times within several hours of using Jay. I'm also not sure if this affects non-flatpak versions which is why I've specified flatpak.
Why do you believe this is caused by the compositor?
Because this only happens in jay. I've never seen this behaviour in Sway, Hyprland, or Niri, but I do see it regularly in Jay.
I've not encountered this situation and I usually keep applications open for several days. I don't use firefox.
Do you have any suggestions on what I should do for adding more information to this issue to help solve this? I would imagine output from WAYLAND_DEBUG would be helpful?
Maybe it would be useful but probably not. If firefox continues accepting input and such and continues rendering except that sites no longer load, then the wayland messages will likely not be useful on their own. You might want to check if firefox emits any error messages on its own. You can also experiment with changing the various dmabuf and wayland setting under about:config.
Your best bet is probably to open a firefox bug ticket and to find a reliable reproducer.
Here's a video of this behaviour. I also just learned that context menus (things like right-click menus) don't seem to appear either.
https://github.com/user-attachments/assets/e938f9c8-72c9-487b-bef8-f59e005cd70d
Here are the wayland_debug files, I've split it into two as I got a copy before recording the video above then figured it would be a good idea to include the logs from after the video. pt1 is right after I came back from around an hour or two of leaving the system to DPMS, it includes me trying to open a new tab and it not working so I copied that to a file. pt2 has after the video was recorded and includes trying to open new tabs, page reloads, trying to open extension menus, managing to get onto the installed extensions page, and context menus.
In pt1, I believe that around 26k lines was when I unlocked my system from and the problematic lines should start to appear. I'm saying 26k roughly, but I'm using line 26586 as my rough guide for this as shortly after zxdg_output catches my display again.
After reproducing this again while running firefox without wayland_debug to see if the cli catches any errors I've only seen the following:
[2] Sandbox: CanCreateUserNamespace() clone() failure: EPERM
Gdk-WARNING **: 22:36:24.293: Server is missing xdg_foreign support
[Parent 2, Main Thread] WARNING: Server is missing xdg_foreign support: 'glib warning', file /builds/worker/checkouts/gecko/toolkit/xre/nsSigHandlers.cpp:201
libva info: VA-API version 1.22.0
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/radeonsi_drv_video.so
libva info: Trying to open /usr/lib/x86_64-linux-gnu/dri/intel-vaapi-driver/radeonsi_drv_video.so
libva info: Trying to open /usr/lib/x86_64-linux-gnu/GL/lib/dri/radeonsi_drv_video.so
libva info: Found init function __vaDriverInit_1_22
libva info: va_openDriver() returns 0
I seemed to have missed this, but it might also be caused by jays security_context_acceptor as I found this in jay log that I seem to have overlooked until now:
jay::security_context_acceptor] Destroying security acceptor org.flatpak/io.gitlab.librewolf-community/1047099687
This was happening with flatpak firefox as well according to the log events prior to this one. A full log of this can be seen below:
[2025-12-17T00:17:14.248Z INFO jay::client] Client 165 connected, pid: 151665, uid: 1000, fd: 166, comm: "flatpak", caps: CAP_DATA_CONTROL_MANAGER|CAP_LAYER_SHELL|CAP_SCREENCOPY_MANAGER
[2025-12-17T00:17:14.248Z INFO jay::security_context_acceptor] Creating security acceptor org.flatpak/io.gitlab.librewolf-community/1267620587
[2025-12-17T00:17:14.248Z INFO jay::client::tasks] Client 165 terminated the connection
[2025-12-17T00:17:14.248Z INFO jay::client] Removing client 165
[2025-12-17T00:17:14.382Z INFO jay::client] Client 166 connected, pid: 151678, uid: 1000, fd: 166, comm: "librewolf", caps: CAP_DATA_CONTROL_MANAGER|CAP_LAYER_SHELL|CAP_SCREENCOPY_MANAGER
[2025-12-17T00:17:14.382Z INFO jay::client::tasks] Client 166 terminated the connection
[2025-12-17T00:17:14.382Z INFO jay::client] Removing client 166
[2025-12-17T00:17:14.382Z INFO jay::client] Client 167 connected, pid: 151678, uid: 1000, fd: 166, comm: "librewolf", caps: CAP_DATA_CONTROL_MANAGER|CAP_LAYER_SHELL|CAP_SCREENCOPY_MANAGER
[2025-12-17T00:17:14.434Z INFO jay::client::tasks] Client 167 terminated the connection
[2025-12-17T00:17:14.434Z INFO jay::client] Removing client 167
[2025-12-17T00:17:14.440Z INFO jay::security_context_acceptor] Destroying security acceptor org.flatpak/io.gitlab.librewolf-community/1267620587
No idea. Afaik all of the window contents are presented via a single subsurface that also includes the navigation elements that continue to work in your video. There must be something broken in the firefox internal state that makes it stop rendering pages but allows it to continue rendering the rest of the window. You should ask firefox developers.
I have never experienced this issue. I usually have two firefox windows with about ~90 tabs open all day. However, I do experience firefox tabs failing to load on my phone, so this may just be a general firefox issue.
I have never experienced this issue. I usually have two firefox windows with about ~90 tabs open all day. However, I do experience firefox tabs failing to load on my phone, so this may just be a general firefox issue.
Are you running the flatpak as well? I'm curious if this issue might just affect the flatpak.
I am not running the firefox flatpak.
Check if Firefox content processes are alive for those tabs when it happens. Think there is a task manager in Firefox that could tell you that (about:processes maybe). That might help track it down further.
This looks very much like what happened when Firefox was unable to communicate with its content processes, but it's been a long time since I've last used Firefox.
Check if Firefox content processes are alive for those tabs when it happens. Think there is a task manager in Firefox that could tell you that (
about:processesmaybe). That might help track it down further.This looks very much like what happened when Firefox was unable to communicate with its content processes, but it's been a long time since I've last used Firefox.
Thanks! I'll definitely look into this the next time I run into this issue. I'm also going to test along side the system package to see if this issue is possibly related to something with the flatpak.
@kotarac The about:processes page looks practically identical from when this happens and from when it's behaving as intended. Just in case I'm overlooking something, here's a screenshot of when this issue happens:
Screenshot of when firefox is behaving normally:
@mahkoh A small update to this, the issue doesn't seem to happen if I have both the flatpak and native package of the browser open. For this test I did the following:
Start jay on latest master Open both Librewolf flatpak and Librewolf native package Let the system idle and hit DPMS for 24 hours each attempt (48 hours total with the two librewolf packages) Librewolf works as intended still after 72+ hours as I'm writing this
I then opened firefox flatpak with the above still open and did the 24 hour idle + DPMS part Firefox flatpak experienced this issue but both Librewolf windows still are working perfectly fine.
I haven't restarted Jay or the browsers at all in this time so it might be a one time coincidence that Librewolf is working as intended this way so I can always test that but I figured this would be useful information to mention. I am about to update to the latest commit of jay again and do a system reboot before trying this again just to make sure it wasn't a one off thing.
I believe I can comfortably narrow this down to this only happening when a flatpak version is the only one on the system running. I removed the native package last week to continue using only the flatpak and I've run into this issue often since then. When I had both the flatpak and the native version running at the same time this issue never occurred, but when having only the flatpak version it does happen.
I'm still pretty sure this is a Jay bug as it doesn't happen on any of the other Wayland Compositors which I actively use. Those include Sway, Hyprland, and Niri.