Display is not capable of DPMS After GNOME Wayland update

dpmsgnomewaylandxset

Seems like GNOME updated to Wayland which caused a few issues, the biggest is the periodic crash that brings you back to the login screen. Another issue that is hopefully easier to fix is that I can no longer put my display to sleep.

Before the update I was using this sh script bound to a shortcut:

sleep 1; xset dpms force off

After it produces the error below:

X Error of failed request:  BadMatch (invalid parameter attributes)
  Major opcode of failed request:  147 (DPMS)
  Minor opcode of failed request:  6 (DPMSForceLevel)
  Serial number of failed request:  12
  Current serial number in output stream:  14

What is the correct way to put the display to sleep manually with Wayland?

Edit:

It appears that the DPMS does not work properly which is the reason for the error.

Check DPMS status:

xset -q

Result:

DPMS (Energy Star):
Display is not capable of DPMS

xset +dpms command does not enable it. It was working before the Gnome update so DPMS was supported. What could be the issue here?

Best Answer

So this here works for GNOME 3.24 Wayland:

put all displays in standby:

busctl --user set-property org.gnome.Mutter.DisplayConfig /org/gnome/Mutter/DisplayConfig org.gnome.Mutter.DisplayConfig PowerSaveMode i 1

Resume all displays:

busctl --user set-property org.gnome.Mutter.DisplayConfig /org/gnome/Mutter/DisplayConfig org.gnome.Mutter.DisplayConfig PowerSaveMode i 0

The command can be given over ssh, just in case ;) There does not seem to be a screen lock.

The GNOMErs decided to have gdm run a separate GNOME X session for screen lock, leading to a host of bugs and problems like what session is shown, what session is locked, what session has the keyboard. This is why blanking and screen lock are absent from the Wayland session.

It seems the World has yet to see a screen lock for Wayland.

Related Question