mail
mail copied to clipboard
Many mails flash to white after opening
What Happened?
It happens very often that after opening a mail it shows for a split-second, but then turns completely white. It also happens with emails from senders where it didn't happen on previous mails (e.g. Collosal).
Closing and re-opening mail does not help, nor does it change which email turns white and which one doesn't. That's always consistent.
2023-09-05-18:02:38.391749663.mkv.tar.gz
Printing the email does work.
Steps to Reproduce
- Click on mail
- It loads and shows
- It flashes completely to white
Expected Behavior
Mail content should not flash to white.
OS Version
7.x (Horus)
Software Version
Latest release (I have run all updates)
Log Output
This is from the syslog, but it also and happens with mails that do load so I'm not sure if it's useful:
Sep 5 20:07:51 Framey io.elementary.m[786301]: MessageListItem.vala:509: Not Found
Sep 5 20:07:51 Framey xdg-desktop-por[2656]: Realtime error: Could not map pid: Could not determine pid namespace: Could not find instance-id in process's /.flatpak-info
Hardware Info
eeeeeeeeeeeeeeeee wout@Framey
eeeeeeeeeeeeeeeeeeeeeee -----------
eeeee eeeeeeeeeeee eeeee OS: elementary OS 7 Horus x86_64
eeee eeeee eee eeee Host: Laptop (12th Gen Intel Core) A8
eeee eeee eee eeee Kernel: 6.2.0-31-generic
eee eee eee eee Uptime: 1 day, 7 hours, 27 mins
eee eee eee eee Packages: 1922 (dpkg), 69 (flatpak)
ee eee eeee eeee Shell: bash 5.1.16
ee eee eeeee eeeeee Resolution: 3000x2000
ee eee eeeee eeeee ee DE: Pantheon
eee eeee eeeeee eeeee eee WM: Mutter(Gala)
eee eeeeeeeeee eeeeee eee Theme: io.elementary.stylesheet.mint [GTK3]
eeeeeeeeeeeeeeeeeeeeeeee eeeee Icons: elementary [GTK3]
eeeeeeee eeeeeeeeeeee eeee Terminal: io.elementary.t
eeeee eeeee CPU: 12th Gen Intel i7-1280P (20) @ 4.700GHz
eeeeeee eeeeeee GPU: Intel Alder Lake-P
eeeeeeeeeeeeeeeee Memory: 14822MiB / 64003MiB
It seems to be related to images. I've turned off Always Show Remote Images, and can now read the emails. But as soon as I hit the Show Images button in the yellow banner at the top of the message viewer, the email flashes to white.
Hmm that seems strange. If you've got a non sensitive message it would be great if you could forward it to [email protected] or upload the source here (using evolution or geary you can download the source of the mail). Apart from that if you scroll all the way down does something show up there? Or is there by any chance a way to scroll within the message?
I've forwarded two of the affected emails.
Yes, I can scroll all the way down. So it's as if the whole email is there, but the content is completely white. This is all the way scrolled down (four pulls on the trackpad):
I've now evaluated it a bit longer, and it's happening consistently with the same newsletters:
- https://www.indiehackers.com/
- https://www.thisiscolossal.com/
Another newsletter with this issue: https://www.designboom.com/
I am experiencing something similar except I can see parts of the message. It has started happening in the last couple of weeks. Turning of show images does not help. Also if I press "Reply" to bring the message up in a separate window, I can read the whole message.
Also if I press "Reply" to bring the message up in a separate window, I can read the whole message.
Same here. Hitting reply is the only way right now to read the messages.
I do not normally develop on Mail but I have had a look at the code and suspect this is a WebKit/WebView issue (or maybe the way we are configuring/using it) resulting in it not being able to properly display the mails produced by the latest email clients (which are stuffed with a lot of complex html). When replying WebView provide a stripped down version of the mail for quoting which can be displayed without problem.
@tintou Are you able to shed any light on this?
Evolution had a similar problem here https://discourse.gnome.org/t/evolution-email-bodies-not-shown-anymore/15219 apparently due to a WebKit update causing a regression.
Looks like we do not have a new enough version of libedataserver to allow use of later versions of webkit. We have version 3.44 which means version 4.0 of webkit is used, not 4.1 or 6.0.
Just now, I came across an email where only part of the content is shown:
So I did some investigation and I think the issue is caused by how the scrolled window and the webview interact. It is AFAIK the only major difference between the composer webview and the one in the messagelistitem apart from some minor html stuff. Also for me this issue didn't happen when I made the window big enough so that no scrolling was needed for the whole message to be displayed. Maybe you could try that as well for a short message? I've got no idea how/if we can fix this though :(
If the message is short, the problem doesn't occur.
For me, this only happens with messages that I need to scroll through.
A little more investigating indicates that the problem is deeper than the scrolled window - the web-view used in the message list does not interact properly with a simple container when it is resized with a Paned. I also notice that in the message list the webview does not honor the system dark setting whereas in the Composer widget it does. I'll try to look into this further when I have time.
I also notice that in the message list the webview does not honor the system dark setting whereas in the Composer widget it does
Just a little note here this is because in the composer we use our own html and do it there, AFAIK the webview can't do anything about the theme
Same problem here, this is actually happening in the browser too.
A workaround currently is to run mail with
WEBKIT_DISABLE_COMPOSITING_MODE=1 io.elementary.mail
which fixes the issue but disables hardware accelerated rendering AFAIK.
For the content of most mails this should be fine though
If you want to permanently do this navigate to system settings -> applications -> startup apps
There disable (important disable and don't delete!) the entry for mail and then add a new entry with the custom command:
WEBKIT_DISABLE_COMPOSITING_MODE=1 io.elementary.mail --background
via the + button in the bottom toolbar
It does work, thanks @leolost2605! I tested with values 1
and 0
and with value 1
the emails render properly. I tried multiple longer emails, even with graphics etc (company emails, newsletters, etc).
I'm using Geary at the moment, which works without issues, but it's good to know about other options. Hope the issue will get fixed soon and we won't need workarounds.