Bug 2193245 - X11+Xwayland: black window when launched. Possibly caused by Xwayland-on-demand or Firefox race condition when switching between composited/non-composited X11
Summary: X11+Xwayland: black window when launched. Possibly caused by Xwayland-on-dema...
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: mutter
Version: 38
Hardware: x86_64
OS: Linux
Target Milestone: ---
Assignee: GNOME SIG Unassigned
QA Contact: Fedora Extras Quality Assurance
: 2196042 (view as bug list)
Depends On:
TreeView+ depends on / blocked
Reported: 2023-05-04 20:20 UTC by John Mellor
Modified: 2024-02-14 11:18 UTC (History)
23 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2023-05-29 12:49:04 UTC
Type: ---

Attachments (Terms of Use)

Description John Mellor 2023-05-04 20:20:35 UTC
After upgrading from F37 to F38, there is an extra package required to successfully read mail after boot.  Unless you manually install thunderbird-wayland package, invoking Thunderbird permanently stalls showing a blackscreen.

Workaround: Killing the blackscreen and invoking Thunderbird a second time then works as expected.

Proposed Fix: If Thunderbird is installed on a Wayland screen, force an install of thunderbird-wayland package.

Reproducible: Always

Steps to Reproduce:
1.On F37, install and configure Thunderbird as you normally would.
2.Upgrade F37 to F38.
3.Invoke Thunderbird.  Note that Thunderbird blackscreens forever.
Actual Results:  
Application blackscreen.

Expected Results:  
Normal Thunderbird operation.

See the discussion "Thunderbird black at first launch with F38" on the Fedora user list (email: users.org) for one instance of the issue and how to resolve it.  The Fedora update tool is missing a step to install the extra package in F38.

Comment 1 Samuel Sieb 2023-05-04 20:33:43 UTC
I meant that you should file an issue on Thunderbird about the black screen.  The updater doesn't know if you're using Wayland or not.
Also, https://bugzilla.redhat.com/show_bug.cgi?id=2177283

Comment 2 Samuel Sieb 2023-05-04 20:35:03 UTC
Can you run Thunderbird from a terminal the first time to see if there are any error messages?

Comment 3 John Mellor 2023-05-04 21:22:56 UTC
There are no error messages when you start Thunderbird from the terminal window.  I also tried the --jsdconsole option, which opens up a debug window that also blackscreens.  Adding in the missing thunderbird-wayland package resolves the problem.  I filed this bug against the upgrader because either it or thunderbird package need to know that Wayland is in use and install the new package as part of the upgrade.

Comment 4 Andre Robatino 2023-05-04 23:35:23 UTC
I have a clean install of F38 and am normally in GNOME on Wayland. For me, Firefox and Thunderbird work normally without either firefox-wayland or thunderbird-wayland installed. The same was true in earlier Fedora versions.

Comment 5 Fred 2023-05-05 10:49:59 UTC
FWIW I have a clean install too and have the bug described.

Comment 6 Eike Rathke 2023-05-08 11:39:15 UTC
*** Bug 2196042 has been marked as a duplicate of this bug. ***

Comment 7 Andre Robatino 2023-05-10 11:02:59 UTC
When I started Thunderbird after logging in, I noticed that there was a black screen for about 1 second before it appeared normally as usual. Normally I wouldn't pay attention to that, but maybe it's related. I restarted it two more times and the black screen appeared for 1 second the second time, but not the third. I'm still not clear on what the purpose of the firefox-{wayland,x11} and thunderbird-wayland packages is, since I've never had to install them for normal operation in either Wayland or Xorg, and I'd have thought that since they're not installed by default, they shouldn't normally be necessary.

Comment 8 John Mellor 2023-05-13 13:37:29 UTC
Workaround: Downgrading from thunderbird-102.10.0-1.fc38.x86_64 to thunderbird-102.9.1-1.fc38.x86_64 resolves this blackscreen bug.
Can we get the thunderbird-102.10.0 version removed from the repo to limit the number of people experiencing this high-visibility bug?

Comment 9 Ben Beasley 2023-05-13 15:45:10 UTC
For me, the window is not black, but there are some tall, narrow black rectangles outside the window when I tile Thunderbird to the left or right half of the screen. Installing thunderbird-wayland and using the “Thunderbird on Wayland” launcher still fixes it, though.

Comment 10 John Mellor 2023-05-19 16:18:27 UTC
Interesting Observation:  I normally start Thunderbird, kill it due to the black-screen and restart it to read my mail.  While I am doing that, I usually also do a dnf update (not using the Gnome Software app due to its major bugs), and then sometimes reboot to pick up the new changes.  Twice now I have warm-rebooted (as opposed to cold shutdown and startup) and Thunderbird has worked correctly after the reboot.  Upon rebooting, I go into Thunderbird again, and it works correctly the first time, without the black-screen debacle.
This result would appear to show that there is an uninitialized variable in the critical chain of actions that is key to the issue.  It also may explain why some people have different defects showing, or be unable to show the fault at all.  I believe that KVM will clean the memory correctly, while a reboot does not.

Comment 11 Geo 2023-05-28 22:54:33 UTC
Just to add a little more to this issue. I am running Thunderbird 102.10.0 with F38 Desktop on Gnome 44.1 and Wayland windowing system. Having used Fedora, Gnome and Thunderbird for many years now as my daily home PC, this is the first time I've had this issue. I have installed the additional thunderbird-wayland package as recommended and the issue persists. The restart of Thunderbird always works after closing the first black window session. Moving the mouse from side to side in the black window, the cursor changes to the double arrow where the folder menu demarcation is. It does not change in the up and down direction where the preview screen demarcation would normally be.

Comment 12 Samuel Sieb 2023-05-28 23:33:51 UTC
If you installed the wayland package, then you need to choose the "Thunderbird on Wayland" option, not the "Thunderbird" one.

Comment 13 John Mellor 2023-05-29 01:15:15 UTC
Samuel stated:
> If you installed the wayland package, then you need to choose the "Thunderbird on Wayland" option, not the "Thunderbird" one.

I went looking.  I'm unsure where you are referring to, but there is no "Thunderbird on Wayland" option.  There is however, a thunderbird-wayland package in the repo that depends on thunderbird.

The problem is that thunderbird-wayland package does not work.  It is broken.  With or without it installed, I can see the mouse tracking over edges as expected, but just over an unusable blackscreen.  Just for grins, I reinstalled:

$ sudo rpm -e thunderbird thunderbird-librnp-rnp-102.10.0-1.fc38.x86_64 thunderbird-wayland
$ sudo dnf install thunderbird-wayland
Fedora 38 - x86_64 - Updates                     59 kB/s |  24 kB     00:00    
Fedora Modular 38 - x86_64 - Updates             68 kB/s |  25 kB     00:00    
RPM Fusion for Fedora 38 - Free tainted          18 kB/s | 3.2 kB     00:00    
Dependencies resolved.
 Package                    Arch       Version                Repository   Size
 thunderbird-wayland        x86_64     102.10.0-1.fc38        updates      12 k
Installing dependencies:
 thunderbird                x86_64     102.10.0-1.fc38        updates     102 M
 thunderbird-librnp-rnp     x86_64     102.10.0-1.fc38        updates     1.2 M

Transaction Summary
Install  3 Packages

Total download size: 103 M
Installed size: 279 M
Is this ok [y/N]: y
Downloading Packages:
(1/3): thunderbird-wayland-102.10.0-1.fc38.x86_  88 kB/s |  12 kB     00:00    
(2/3): thunderbird-librnp-rnp-102.10.0-1.fc38.x 2.5 MB/s | 1.2 MB     00:00    
(3/3): thunderbird-102.10.0-1.fc38.x86_64.rpm    18 MB/s | 102 MB     00:05    
Total                                            17 MB/s | 103 MB     00:06     
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                        1/1 
  Installing       : thunderbird-librnp-rnp-102.10.0-1.fc38.x86_64          1/3 
  Installing       : thunderbird-102.10.0-1.fc38.x86_64                     2/3 
  Running scriptlet: thunderbird-102.10.0-1.fc38.x86_64                     2/3 
  Installing       : thunderbird-wayland-102.10.0-1.fc38.x86_64             3/3 
  Running scriptlet: thunderbird-102.10.0-1.fc38.x86_64                     3/3 
  Running scriptlet: thunderbird-wayland-102.10.0-1.fc38.x86_64             3/3 
  Verifying        : thunderbird-102.10.0-1.fc38.x86_64                     1/3 
  Verifying        : thunderbird-librnp-rnp-102.10.0-1.fc38.x86_64          2/3 
  Verifying        : thunderbird-wayland-102.10.0-1.fc38.x86_64             3/3 



Then, running Thunderbird does the exact same thing - blackscreen on first use.  On second use, it works as intended.

Comment 14 Samuel Sieb 2023-05-29 01:24:52 UTC
I don't know which desktop you're using, but after you install that package, you will have two Thunderbird program options, one that has "on Wayland" in the name.  That's the one you need to use to avoid this issue.

Comment 15 Fred 2023-06-27 03:12:07 UTC
I'm surprised this is closed. For the past week at least, whichever package you launch first it either crashed, or give you the black screen, then you run the other Thunderbird package and it works normally. Is this really going to stay closed?

Comment 16 Martin Stransky 2023-06-27 07:55:34 UTC
We're going to run Thunderbird on Wayland by default for next TB line based on Firefox 115. Until that TB will remain X11 application. What you see is a general bug in XWayland and affects Firefox in X11 mode too. AFAIK it was addressed in mutter somehow. See https://bugzilla.mozilla.org/show_bug.cgi?id=1788205

This patch is used by Debian for Mutter:

Note You need to log in before you can comment on or make changes to this bug.