Announcements

Help Wizard

Step 1

NEXT STEP

Wayland support

Wayland support

Hi,

Can you release a linux package with ozone support built so that we can use the client under Wayland? There have been posts requesting this in the past because it is highly anticipated.

 

It shouldn't be that complicated it seems:

https://www.collabora.com/news-and-blog/blog/2019/05/08/cef-on-wayland-upstreamed/

https://chromium.googlesource.com/chromium/src/+/refs/heads/main/docs/ozone_overview.md

 

Best,

Reply
134 Replies

Yeah, I know it's not ideal, but now I can wait for the fix in peace 😂! Thanks for your attention! I heard there aren't many Linux developers on the Spotify team. You Rock! 🤘

/chromiumembedded/cef/issues/4061#issuecomment-3697132275
magreenblatt on github:
This frame is likely rendered by Chromium's DefaultFrameView.
Creating a custom FrameView is complicated (you can see the amount of code involved) and would more appropriately be implemented in Chromium instead of CEF.

Hmm 

Spotify 1.2.86.502 doesn't allow to run via Wayland, it seems to be Xorg only and runs via Xwayland even if 

--enable-features=UseOzonePlatform
--ozone-platform=wayland

are set... Ridiculous in 2026.

@no4b  Spotify runs natively in Wayland if you pass "--enable-features=UseOzonePlatform --ozone-platform=wayland"

If you can't, it might be a specific issue in your set-up

@pgomes:

Are you sure about that? I tried:

/opt/spotify/spotify --enable-features=UseOzonePlatform --ozone-platform=wayland --show-console

so that no wrapper is involved.

 

This is what xwininfo reports:

$ xwininfo  

xwininfo: Please select the window about which you
         would like information by clicking the
         mouse in that window.

xwininfo: Window id: 0x1000004 "Spotify Premium"

 Absolute upper-left X:  1920
 Absolute upper-left Y:  28
 Relative upper-left X:  1920
 Relative upper-left Y:  28
 Width: 1920
 Height: 1172
 Depth: 24
 Visual: 0x25
 Visual Class: TrueColor
 Border width: 0
 Class: InputOutput
 Colormap: 0x24 (installed)
 Bit Gravity State: NorthWestGravity
 Window Gravity State: NorthWestGravity
 Backing Store State: NotUseful
 Save Under State: no
 Map State: IsViewable
 Override Redirect State: no
 Corners:  +1920+28  -0+28  -0-0  +1920-0
 -geometry 1920x1172-0-0

On Wayland it would show nothing. I think that an issue specific to my setup is highly unlikely because 1.2.84.476 runs natively on Wayland on exactly the same system. Only Spotify version has changed and newer version doesn't seem to be running natively on Wayland from what I see.

@no4b you are right. I replied after running 1.2.84.476.ga1ff6607, which supports correctly run in Wayland. But now running a local build (I'm an engineer), I confirmed problem. Also, I confirm that it was not intentional to drop Wayland support and rely on X11 emulation, as you hinted with your original post. This is a bug, which I am already looking at.

There is a workaround to the problem: unset DISPLAY env. Then, the client should work as usual in Wayland. Shouldn't even need the switches, as Wayland has recently became the default

Thank you for taking a look into this 🙂

I confirm that unsetting DISPLAY env makes Spotify run in Wayland. However it would be preferable it if started in Wayland even when this variable is present because it might be necessary for another software and is commonly set by default.

 

I would also greatly appreciate it if you could take a look at the sample rate issue I described here https://community.spotify.com/t5/Desktop-Linux/Regression-1-2-86-502-doesn-t-set-correct-sample-rate...

 

Got it. Unsetting DISPLAY is just a temporary workaround. We are already working on a fix. However, I can't promise dates. As you might know, we only get a few hours per month to work at the Linux client. I update it here once I have some progress.

Just wanted to give a shoutout here in this thread and say thank you! in the latest version CSD now works, look how beautiful it is: 

MM147_0-1777281783012.png

 

Awesome work! 🙂

What version is this? In the stable and edge snap versions, I don't see this on Ubuntu 26.04 LTS.

i'm on this version: 

Spotify for Linux
1.2.86.502.g8cd7fb22

Doesn't seem like that version has any changes wrt window decorations. Installed it and launched under Wayland with "DISPLAY= snap run spotify" to make sure it didn't launch with XWayland, and I still see the typical blue border.

Can confirm the latest 1.2.86.502... version has fixed this. On Ubuntu, you have to switch to latest/edge channel in App Center's Spotify page to recieve this version. Thank you so much to everyone involved. 

Hi all. Actually, it not properly fixed. What was done is that some code to test if it was X11 session added. But the code is incorrectly forcing to use XWayland (X11 emulation), which doesn't have the ugly blue window decoration. If you unset your DISPLAY variable, you'll run in native Wayland, and will once see the blue window decoration

Good news is that the problem has two different fix proposals. One comes directly from Chromium (here and here). I have submitted another one, to CEF (it's PR #4178 in CEF's Github - I can't link it here). Both seem to do the same, in essence: rework the default window decoration to use GTK. That way, if your Wayland composer (here, the equivalent for X11's Display server + window manager) does not support xdg-decoration protocol (i.e., KDE/Plasma does, Gnome doesn't), it will fall back to the GTK's window decorator.

Suggested posts

Let's introduce ourselves!

Hey there you,   Yeah, you! 😁   Welcome - we're glad you joined the Spotify Community!   While you here, let's have a fun game and get…

ModeratorStaff / Moderator/ 4 years ago  in Social & Random