Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Element not Rendering Graphics #1029

Open
InklingGirl opened this issue Jun 21, 2023 · 26 comments
Open

Element not Rendering Graphics #1029

InklingGirl opened this issue Jun 21, 2023 · 26 comments

Comments

@InklingGirl
Copy link

InklingGirl commented Jun 21, 2023

Steps to reproduce

  1. Where are you starting? What can you see?
    Open Element as per standard on a GNOME desktop, but the window proceeds to flash & goes on to not render anything but a text cursor at the bottom of it.
    Screenshot from 2023-06-21 22-46-44
    Even the topbar icon is caught up in this, as it briefly renders on launching the program & then visually disappears (while still being clickable).
  2. No more steps, just doesn't work lol.

Outcome

What did you expect?

For Element to render correctly.

What happened instead?

On opening, the window proceeds to flash & go on to not render anything but a text cursor at the bottom of it.
Screenshot from 2023-06-21 22-46-44

Operating system

Ubuntu 22.04.2 LTS (Jammy Jellyfish) OS w/ GNOME 42.5 DE on Wayland window server

Application version

Can't see, but latest

How did you install the app?

https://packages.element.io/debian/ i.e. the first-party Deb repo for Element, via apt

Homeserver

No response

Will you send logs?

Yes

@t3chguy t3chguy transferred this issue from element-hq/element-web Jun 21, 2023
@InklingGirl
Copy link
Author

I still need help w/ this, I'm not able to use Element at all until it's resolved. I wonder, would turning off hardware acceleration be a working temporary stopgap? I can't see any of the menus, so I can't change the setting graphically, but is it represented in a config file? Thanks.

@InklingGirl
Copy link
Author

In my case at least, using ppa-purge to remove ppa:ernstp/mesarc (the PPA from which I was getting graphics drivers) & downgrade the graphics packages seems to have fixed element-desktop's rendering issues. Still, I would like a response to my above enquiry about switching element-desktop to software mode w/o access to the GUI before I consider closing this issue. Thanks.

@pbsds
Copy link

pbsds commented Jun 29, 2023

try running with --disable-gpu --in-process-gpu

@InklingGirl
Copy link
Author

Thanks for the tip @pbsds, this is no longer an issue for me, but it might be helpful in the future to have that command.

@InklingGirl
Copy link
Author

W/ the build of Mesa Canonical ships & also the current build of Mesa from ppa:kisak/kisak-mesa, this issue doesn't persist for me.

@sascha-wi
Copy link

--disable-gpu --in-process-gpu

this helped me with my issue, but why is this neccessary now? It worked fine before. I am on debian testing.

@pbsds
Copy link

pbsds commented Jul 5, 2023

I've had issues with multiple electron applications, where the fix was the same. Could be an electron update thing

@InklingGirl
Copy link
Author

Is brave-browser Electron? I had the same issue w/ that.

@t3chguy
Copy link
Member

t3chguy commented Jul 5, 2023

@InklingGirl brave is based on Chromium, Electron is also based on Chromium.

@InklingGirl
Copy link
Author

Maybe an even upperstream issue then? Who knows, but for reference:
brave/brave-browser#30180

@InklingGirl
Copy link
Author

If anyone is still experiencing, I may reopen

--disable-gpu --in-process-gpu

this helped me with my issue, but why is this neccessary now? It worked fine before. I am on debian testing.

Since @sascha-wi is still experiencing, I'll reopen this.

@fogti
Copy link

fogti commented Jul 8, 2023

So uhh did anyone file an Electron/chromium issue for that?

@ailequal
Copy link

I can also confirm that with the flag --disable-gpu --in-process-gpu Element is starting fine. I am on Ubuntu 22.04. I remember that I recently got a new update for Element, but I have no idea if the issue is somehow related. My GPU is a RX 580.

@MiquelRForgeFlow
Copy link

I can confirm getting the same issue in the last update (flag --disable-gpu --in-process-gpu temporarily solves it, but it's a pain having to maintain a terminal opened). Hope it's solved soon. I have Ubuntu 22.04.2 LTS with AMD Ryzen 7 Graphics (Renoir).
Selection_1506

@ailequal
Copy link

I can confirm getting the same issue in the last update (flag --disable-gpu --in-process-gpu temporarily solves it, but it's a pain having to maintain a terminal opened). Hope it's solved soon. I have Ubuntu 22.04.2 LTS with AMD Ryzen 7 Graphics (Renoir). Selection_1506

You can use the following alias which won't hang your terminal (it works with bash).
alias element-desktop-gpu="element-desktop --disable-gpu --in-process-gpu &> /dev/null &"

@pbsds
Copy link

pbsds commented Jul 12, 2023

On nixos i modify the desktop entry with an override:

  nixpkgs.config.packageOverrides = pkgs: {
    element-desktop = pkgs.element-desktop.overrideAttrs (old: {
      desktopItem = old.desktopItem.override (old: {
        exec = "element-desktop --disable-gpu --in-process-gpu %u";
      });
    });
  };

@Taranchul
Copy link

Taranchul commented Jul 22, 2023

I found a solution in another issue that fixed the white screen for me: Delete the contents of ~/.config/Element/GPUCache (or ~/.config/Riot/GPUCache if you upgraded to Element from Riot).

edit: Ah, I just saw that this is also mentioned in joepie91's link to nixpkgs.

@sascha-wi
Copy link

I found a solution in another issue that fixed the white screen for me: Delete the contents of ~/.config/Element/GPUCache (or ~/.config/Riot/GPUCache if you upgraded to Element from Riot).

edit: Ah, I just saw that this is also mentioned in joepie91's link to nixpkgs.

Worked for me aswell.

@NOFUNEVER
Copy link

Was using Element last night without issue, this morning Element started showing this issue, additionally chrome wasn't rendering correctly. Reinstalling chrome would fix the problem with chrome but as soon as I opened element up it would return. removing the contents of ~/.config/Element/GPUCache as recommend above seems to have fixed both the issue with element and it's strange interaction with my browser.

@Taranchul
Copy link

Same here. Yesterday's update from https://packages.element.io/debian caused the white window again, removal of GPUCache/* fixed it again.

Maybe Element should empty that directory on startup or after an update as a temporary solution until the real reason is found and fixed?

@Taranchul
Copy link

Taranchul commented Jul 29, 2023

Reinstalling chrome would fix the problem with chrome

Chrome has its own cache directories. You could try to empty them or at least GPUCache the next time (maybe after a backup):

~/.config/google-chrome/GrShaderCache
~/.config/google-chrome/ShaderCache
~/.config/google-chrome/Default/GPUCache

(Source)

@sascha-wi
Copy link

sascha-wi commented Aug 7, 2023

So today nothing works anymore? regardless how I start element-desktop it shows basically just black background?

Edit:
#1074 (comment) same issue, deleting GPUCache and starting it with --disable-gpu --in-process-gpu makes it work again.

can we finally get a fix for this mess?

@progserega
Copy link

With AMD videocard element-nightly not started on wayland.
With --disable-gpu --in-process-gpu element-desktop-nightly was started success.

log not success start was:

element-desktop-nightly --enable-features=UseOzonePlatform --ozone-platform=wayland  --ozone-platform-hint=auto                                 
/home/progserega/.config/Element-Nightly exists: yes
/home/progserega/.config/Riot-Nightly exists: no
Enabling Sentry with dsn=https://[email protected]/6 environment=nightly
Starting auto update with base URL: https://packages.element.io/nightly/update/
Auto update not supported on this platform
Fetching translation json for locale: en_EN
Changing application language to ru
Fetching translation json for locale: ru
Resetting the UI components after locale change
Resetting the UI components after locale change
[43757:1208/061947.412899:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: Нет такого файла или каталога (2)
[43757:1208/061947.413015:ERROR:gbm_pixmap_wayland.cc(82)] Cannot create bo with format= RGBA_8888 and usage=SCANOUT
[43757:1208/061947.413092:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: Нет такого файла или каталога (2)
[43757:1208/061947.413153:ERROR:gbm_pixmap_wayland.cc(82)] Cannot create bo with format= RGBA_8888 and usage=GPU_READ
[43757:1208/061947.413204:ERROR:shared_image_factory.cc(926)] CreateSharedImage: could not create backing.
[43757:1208/061947.413258:ERROR:shared_image_factory.cc(758)] DestroySharedImage: Could not find shared image mailbox
[43757:1208/061947.413378:ERROR:gpu_service_impl.cc(1089)] Exiting GPU process because some drivers can't recover from errors. GPU process will restart shortly.
[43774:1208/061947.421130:ERROR:command_buffer_proxy_impl.cc(127)] ContextResult::kTransientFailure: Failed to send GpuControl.CreateCommandBuffer.
[43690:1208/061947.423233:ERROR:gpu_process_host.cc(991)] GPU process exited unexpectedly: exit_code=8704
[43794:1208/061947.572526:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: Нет такого файла или каталога (2)
[43794:1208/061947.572744:ERROR:gbm_pixmap_wayland.cc(82)] Cannot create bo with format= RGBA_8888 and usage=SCANOUT
[43794:1208/061947.572892:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: Нет такого файла или каталога (2)
[43794:1208/061947.573056:ERROR:gbm_pixmap_wayland.cc(82)] Cannot create bo with format= RGBA_8888 and usage=GPU_READ
[43794:1208/061947.573169:ERROR:shared_image_factory.cc(926)] CreateSharedImage: could not create backing.
[43794:1208/061947.573259:ERROR:shared_image_factory.cc(758)] DestroySharedImage: Could not find shared image mailbox
[43794:1208/061947.573402:ERROR:gpu_service_impl.cc(1089)] Exiting GPU process because some drivers can't recover from errors. GPU process will restart shortly.
[43774:1208/061947.580940:ERROR:command_buffer_proxy_impl.cc(319)] GPU state invalid after WaitForGetOffsetInRange.
[43690:1208/061947.581876:ERROR:gpu_process_host.cc(991)] GPU process exited unexpectedly: exit_code=8704
[43806:1208/061947.721218:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: Нет такого файла или каталога (2)
[43806:1208/061947.721376:ERROR:gbm_pixmap_wayland.cc(82)] Cannot create bo with format= RGBA_8888 and usage=SCANOUT
[43806:1208/061947.721459:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: Нет такого файла или каталога (2)
[43806:1208/061947.721519:ERROR:gbm_pixmap_wayland.cc(82)] Cannot create bo with format= RGBA_8888 and usage=GPU_READ
[43806:1208/061947.721594:ERROR:shared_image_factory.cc(926)] CreateSharedImage: could not create backing.
[43806:1208/061947.721652:ERROR:shared_image_factory.cc(758)] DestroySharedImage: Could not find shared image mailbox
[43806:1208/061947.721849:ERROR:gpu_service_impl.cc(1089)] Exiting GPU process because some drivers can't recover from errors. GPU process will restart shortly.
[43774:1208/061947.729367:ERROR:command_buffer_proxy_impl.cc(127)] ContextResult::kTransientFailure: Failed to send GpuControl.CreateCommandBuffer.
[43690:1208/061947.730242:ERROR:gpu_process_host.cc(991)] GPU process exited unexpectedly: exit_code=8704
[43690:1208/061947.757581:ERROR:nss_util.cc(357)] After loading Root Certs, loaded==false: NSS error code: -8018
[43774:1208/061947.867456:ERROR:command_buffer_proxy_impl.cc(127)] ContextResult::kTransientFailure: Failed to send GpuControl.CreateCommandBuffer.
[43690:1208/061948.258750:ERROR:object_proxy.cc(577)] Failed to call method: org.freedesktop.DBus.StartServiceByName: object_path= /org/freedesktop/DBus: org.freedesktop.DBus.Error.NoReply: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Changing application language to ru
Fetching translation json for locale: ru
Resetting the UI components after locale change

@pbsds
Copy link

pbsds commented Dec 8, 2023

For the record, i've switched to the following electron flag, which at least give be a smidgen of performance:

element-desktop --use-gl=desktop 

@pbsds
Copy link

pbsds commented Jan 11, 2024

FTR, this is not an issue on nixos 23.11: no workaround needed and i get hardware acceleration finally.

This can maybe be closed

@sascha-wi
Copy link

FTR, this is not an issue on nixos 23.11: no workaround needed and i get hardware acceleration finally.

This can maybe be closed

Just because you have no issues on your OS doesn't mean the issue can be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

10 participants