Under Wayland, popup windows can vanish behind the file save dialog and become nearly impossible to access
🐞 Bug Report
Whonix currently uses the labwc Wayland compositor as our display server. If a permission error occurs while using the file save dialog, a popup appears that informs the user of the error and includes an "OK" button. If the user then clicks outside of the popup rather than clicking "OK", the popup vanishes behind the download window. This results in a semi-deadlock; the save dialog refuses all user interaction (including moving the window!) because of the popup, but the popup is covered by the save dialog. The popup can't be accessed with Alt + Tab either. The browser itself is frozen waiting for the save dialog, so the browser now appears hopelessly frozen.
The only way I've found to work around this so far is to use Alt + Left Click + drag to force the save dialog to move. This allows getting to the popup again, at which point one can click "OK" and unfreeze the save dialog. This is not a method of window movement most users will likely know how to use.
Reproduction steps
- Ensure you are using a system with the labwc Wayland compositor (such as Whonix).
- Open Tor Browser, and navigate to a website you can download something from. (I used Pixabay.)
- Download something from the website.
- When the dialog appears asking if you want to open or save the file, click "Save File".
- When the file save dialog appears, navigate to the system's root directory.
- Click the "Add Folder" button immediately underneath "Save", type in "test", and click "Create". A popup will appear stating "The folder could not be created - Error creating directory /test: Permission denied".
- Click outside the popup, on the file save dialog.
Expected behaviour
It should be possible to get back to the error popup to click "OK" using some mechanism most users will know in advance. Either the save dialog should be able to be moved, or the error popup should be able to be reached with Alt + Tab, or the error popup should remain above all windows, or some other intuitive user interaction should allow getting back to the popup.
Actual behaviour
No intuitive user interaction can get back to the popup.
User impact
Users think the browser is frozen and can't be unfrozen without killing the browser. Example bug report for Whonix: https://forums.whonix.org/t/whonix-18-0-8-7-released-major-release-upgrade/22469/18
Bookkeeping
- Browser version: 15.0.3
- Browser channel:
- Release
- Alpha
- Nightly
- Distribution method:
- Installer/archive from torproject.org
- tor-browser-launcher
- homebrew
-
other (please specify): Archive from torproject.org, but installed using Whonix's
update-torbrowsermechanism
- Operating System:
-
Windows
- Version:
-
macOS
- Version:
-
Linux
- Distribution + Version: Whonix 18 (based on Debian 13)
- Desktop Environment + Version: LXQt 2.1.0 + labwc 0.8.3
-
Android
- Version:
- Device:
- Tails
- Other (please specify):
-
Windows
Browser UI language
English (en-US)
Have you modified any of the settings in about:preferences or about:config? If yes, which ones?
No.
Do you have any extra extensions installed?
No.
Troubleshooting
Does this bug occur in a fresh installation?
Yes.
Is this bug new? If it is a regression, in which version of the browser did this bug first appear?
Not sure, I expect this is probably some way in which GTK is interacting with Wayland.
Does this bug occur in the Alpha release channel?
Yes, it does.
Does this bug occur in Firefox ESR (Desktop only)?
Yes, it does.
Does this bug occur in Firefox Rapid Release?
No, it does not, at least not when using the Firefox Rapid Release Flatpak. The file save dialog looks very different, and the error popup correctly remains on top of all other windows even when the file save dialog is clicked. I'm guessing it's using the XDG desktop portal rather than a native save dialog.