Following Doesn't Visual Studio Code not start with Wayland? - #3 by TheRaOct the proposed solution doesn’t seem to work anymore.
By running Visual Studio Code with
--enable-features=UseOzonePlatform --ozone-platform=wayland it does not crash immediately, but it does crash as soon as I move the mouse or try to interact with its window.
I’m currently using wayland/plasma and
So far it seems to work without problems.
I’m not using any options to start it.
Could be a graphics driver issue. Can you show the output of
aur/visual-studio-code-bin; I have no problem in KDE/Wayland: the problem is only on Hyprland.
Concerning the graphic driver issue, I have the same problem in all my installations of Hyprland (3 laptops and 1 desktop).
This is the result of my LG GRAM:
❯ inxi -Gza
Device-1: Intel TigerLake-LP GT2 [Iris Xe Graphics] vendor: LG driver: i915
v: kernel arch: Gen-12.1 process: Intel 10nm built: 2020-21 ports:
active: eDP-1 empty: DP-1,DP-2,HDMI-A-1 bus-ID: 00:02.0 chip-ID: 8086:9a49
Device-2: Realtek LG Camera driver: uvcvideo type: USB rev: 2.0
speed: 480 Mb/s lanes: 1 mode: 2.0 bus-ID: 3-2:2 chip-ID: 0bda:5641
class-ID: 0e02 serial: <filter>
Display: wayland server: X.org v: 220.127.116.11 with: Xwayland v: 23.2.2
compositor: Hyprland driver: X: loaded: modesetting
alternate: fbdev,intel,vesa dri: iris gpu: i915 display-ID: 1
Monitor-1: eDP-1 model: LG Display 0x0694 built: 2020 res: 2560x1600
dpi: 189 gamma: 1.2 size: 344x215mm (13.54x8.46") diag: 406mm (16")
ratio: 16:10 modes: 2560x1600
API: EGL v: 1.5 hw: drv: intel iris platforms: device: 0 drv: iris
device: 1 drv: swrast surfaceless: drv: iris wayland: drv: iris x11:
drv: iris inactive: gbm
API: OpenGL v: 4.6 compat-v: 4.5 vendor: intel mesa v: 23.2.1-arch1.2
glx-v: 1.4 direct-render: yes renderer: Mesa Intel Xe Graphics (TGL GT2)
device-ID: 8086:9a49 memory: 14.96 GiB unified: yes
Sorry, I’m not familiar with hyprland, hopefully someone who is will chime in.
Thanks for the output, that may help.
Any particular reason not to use the ‘code’ package from Arch? It is still based on vs-codium (ie: stripped) AFAIK? I’m not on Hyprland either, in fact I only tried a Wayland to check operation, but no probs…
Oh - BTW - AMD all the way here… so probably not relevant!
I was using the AUR package because that’s the only one that I could connect to Gitpod (https://www.gitpod.io/) at least in my early experiments. However, I can do without.
extra/code replacing the AUR package.
With no options, on Hyprland, it’s pixellated; with
--ozone-platform=wayland, it looks fine and it does not crash.
I tried with
--ozone-platform-hint=auto it crashes once… once it crashes, it will keep on crashing from then on (!)
I had to remove the directories in
Code - OSS. Now it works again with
--ozone-platform=wayland… I’ll stick with that and stop experimenting further…
Great to hear it works now!
This thread will make life easier for other wayland/hyprland/code users too.