shiftkey / desktop

Fork of GitHub Desktop to support various Linux distributions
MIT License
6.81k stars 518 forks source link

Github Desktop does not work on Wayland with multiple GPUs #1019

Open Covkie opened 7 months ago

Covkie commented 7 months ago

The problem

Launching Github Desktop under Wayland results in

$ github-desktop --enable-features=UseOzonePlatform --ozone-platform=wayland
[17511:0306/194931.669075:ERROR:gpu_process_host.cc(957)] GPU process exited unexpectedly: exit_code=8704
[17858:0306/194931.875357:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
[17858:0306/194931.875491:ERROR:gbm_pixmap_wayland.cc(82)] Cannot create bo with format= RGBA_8888 and usage=SCANOUT
[17858:0306/194931.875657:ERROR:gbm_wrapper.cc(253)] Failed to export buffer to dma_buf: No such file or directory (2)
[17858:0306/194931.875708:ERROR:gbm_pixmap_wayland.cc(82)] Cannot create bo with format= RGBA_8888 and usage=GPU_READ
[17858:0306/194931.875756:ERROR:shared_image_factory.cc(751)] CreateSharedImage: could not create backing.
[17858:0306/194931.875833:ERROR:shared_image_factory.cc(604)] DestroySharedImage: Could not find shared image mailbox
[17858:0306/194931.875994:ERROR:gpu_service_impl.cc(1054)] Exiting GPU process because some drivers can't recover from errors. GPU process will restart shortly.
[17511:0306/194931.885705:ERROR:gpu_process_host.cc(957)] GPU process exited unexpectedly: exit_code=8704

Release version

Version 3.3.8-linux2 (x64)

Operating system

Arch Linux - Plasma 6 Wayland

Steps to reproduce the behavior

  1. Open your terminal and run $github-desktop --enable-features=UseOzonePlatform --ozone-platform=wayland.
  2. Observe

Log files

2024-03-07.desktop..log

Screenshots

No response

Additional context

No response

Covkie commented 7 months ago

Update: I run a dual gpu setup (laptop) - Nvidia dGPU, AMD iGPU. Disabling the Nvidia gpu and running purely with the iGPU allows Desktop to run fine with github-desktop --ozone-platform=wayland. On my system the only other electron application which has this same issue is lunar client. Perhaps this is an upstream electron bug.

What i find weird is i am not running GH Desktop nor Lunar Client on the dGPU..?

shiftkey commented 6 months ago

3.3.8-linux2 (x64)

This version is Electron v26, and I've published 3.3.12-linux2 which is Electron v28. I would advise re-testing when that version is available on Arch and seeing if this behaviour changes at all.

theofficialgman commented 6 months ago

likely related to (unfixed) upstream chromium bug with multiple GPUs on wayland https://issues.chromium.org/issues/327780954

please test on upstream chromium/chrome with the same options and report there

Covkie commented 6 months ago

can confirm it does not work on 3.3.12-linux2 and is likely the issue @theofficialgman linked.