Skip to content

Brave stopped working with OzonePlatform Wayland since 1.65.114 #576

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

Closed
Malom-ctrl opened this issue Apr 18, 2024 · 17 comments
Closed

Brave stopped working with OzonePlatform Wayland since 1.65.114 #576

Malom-ctrl opened this issue Apr 18, 2024 · 17 comments

Comments

@Malom-ctrl
Copy link
Contributor

For those who had previously set the chrome/brave OzonePlatform flag to Wayland, Brave is likely refusing to launch since the last update. Here is how to fix it :

  • Go to ~/.var/app/com.brave.Browser/config
  • Create a file named brave-flags.conf if it doesn't already exist.
  • In brave-flags.conf, add the following line :
    --ozone-platform=wayland
  • Launch Brave, it should now work
  • If it still doesn't work make sure Brave's flatpak has the Wayland permission (You can do that using Flatseal)

Hope this helps.

@zeroskyx
Copy link

zeroskyx commented Apr 18, 2024

Works like a charm -- thanks mate!

Note: if you're using a non-Flatpak version, the respective file will be ~/.config/brave-flags.conf

@mak448a
Copy link

mak448a commented Apr 18, 2024

You mean ~/.config/BraveSoftware/Brave-Browser/brave-flags.conf? I tried that and it didn't work.

@zeroskyx
Copy link

You mean ~/.config/BraveSoftware/Brave-Browser/brave-flags.conf? I tried that and it didn't work.

It's directly in ~/config/ without any additional sub-directories. If the file does not exist, simply create it and you should be good to go 🙂

@mak448a
Copy link

mak448a commented Apr 18, 2024

Oh ok! 👍🏻

@mak448a
Copy link

mak448a commented Apr 18, 2024

@zeroskyx It's still running on xwayland even though I did that 🤔

@zeroskyx
Copy link

Check if you still have experimental flags (brave://flags) enabled (mainly the ozone platform override), and also double-check that Brave is actually consuming ~/.config/brave-flags.conf.

Do do the latter:

  1. Remove the file, start Brave and ensure that brave://gpu/ lists Ozone platform = x11
  2. Close Brave and create ~/.config/brave-flags.conf again with only the content --ozone-platform=wayland
  3. Re-start Brave and ensure that brave://gpu/ lists Ozone platform = wayland and also has --ozone-platform=wayland in the Command Line field
  4. If the last step did not work, try to put something else into ~/.config/brave-flags.conf like --incognito and check if re-starting the browser opens it incognito
  5. If that still does not work, Brave somehow does not respect the file 😞

Note: ensure that all Brave instances are terminated (killall brave) to ensure that it takes the new configuration.

@mak448a
Copy link

mak448a commented Apr 19, 2024

I added --incognito to brave-flags.conf and it still doesn't respect it. However, now brave-browser --ozone-platform=wayland works for me.

@bbb651
Copy link

bbb651 commented Apr 19, 2024

PWAs are also completely broken unless an existing instance of brave that isn't broken is already open, and they do not pick up brave-flags.conf, they can be fixed by manually editing the brave-*.desktop entries

@refi64
Copy link
Contributor

refi64 commented Apr 19, 2024

flathub/org.chromium.Chromium#385

This is an upstream bug and specifically applies if you set the "Preferred Ozone platform" / ozone-platform-hint option. You should be able to run Chromium with --ozone-platform=wayland to work around it.

@cyangalaxy
Copy link

cyangalaxy commented Apr 19, 2024

Hm...I did this workaround 1-2 days ago (thank you for it!), and while it does work, now my Brave seems to freeze occassionally... :S

I would have a couple tabs open, scroll & interact with a webpage, and then Brave is frozen all of a sudden. I close & re-open Brave, and I'm met with "Brave crashed. Restore windows?"

I've switched to Firefox as my main now (I like it equally as much), and keep Brave as backup. Since it appears to be a general Chromium bug, I'll keep an eye if the Chromium team fixes this.

@mihaiplesa
Copy link
Collaborator

mihaiplesa commented Apr 19, 2024

@mihaiplesa
Copy link
Collaborator

@sojusnik
Copy link

sojusnik commented Apr 25, 2024

Shipped in https://github.com/brave/brave-browser/releases/tag/v1.65.122

I'm currently using Version 1.65.122 (Chromium: 124.0.6367.82) on Ubuntu with Wayland, but even with ozone platform = wayland it's still on X11, although in the versions before this issue Wayland worked fine:

grafik

grafik

grafik

@mihaiplesa
Copy link
Collaborator

@sojusnik that sounds like a different issue, have you looked through https://github.com/brave/brave-browser/issues?

@wknapik
Copy link
Collaborator

wknapik commented Apr 25, 2024

brave/brave-browser#37860

@loeeeee
Copy link

loeeeee commented Apr 29, 2024

I was using fedora and running Brave-nightly, and I met the same problem. To disable the ozone flag, I ran

brave-browser-nightly --no-experiments

It opens the browsers with all the flag disabled. And then I went to brave://flags to disable the ozone flag.

@Malom-ctrl
Copy link
Contributor Author

I was using fedora and running Brave-nightly, and I met the same problem. To disable the ozone flag, I ran

brave-browser-nightly --no-experiments

It opens the browsers with all the flag disabled. And then I went to brave://flags to disable the ozone flag.

By doing so you no longer run your browser with Wayland but with X11 instead, which is probably not what you want if you changed your ozone flag to use Wayland in the first place.

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

No branches or pull requests

10 participants