manjaro-pinephone / phosh

Manjaro Phosh
164 stars 20 forks source link

Phosh 0.28.0 wakes up screen because of suspend notification, and phone never suspend, killing battery life #79

Open milkokr opened 1 year ago

milkokr commented 1 year ago

With the Beta 33 from yesterday, the phone no longer suspends. The issue is that Phosh 0.28.0 now wakes up screen on notification, and for some reason a notification is sent that the phone is about to be suspended a minute or so before the suspend. The screen is woken up, which somehow cancels the suspend.

As a workaround, disabling the notifications for urgency of critical fixes the issue, and the phone suspends again.

gsettings set sm.puri.phosh.notifications wakeup-screen-triggers "['category']"
gsettings set sm.puri.phosh.notifications wakeup-screen-categories "['x-gnome.clock.alarm', 'im']"

(The default wakeup-screen-triggers are ['urgency'], and the urgencies contain ['critical'], which my workaround does not touch)

This shouldn't happen. Either there should not be such notification (it had been problematic even before that change, since the blue LED makes one wake up the phone to see what the notification is) Or the notification for suspending should be ignored by phosh explicitly. This solution would make it an upstream phosh issue, but I didn't report it there, because I have no clue who and why is sending this notification, and whether it exists on other operating systems, thereby I don't know if they can do anything about it without knowing this information.