"Computer will suspend very soon because of inactivity." dialog when resuming from suspend

Bug #1232454 reported by Thomas Novin
This bug report is a duplicate of:  Bug #1345116: Computer fails to autosuspend. Edit Remove
584
This bug affects 123 people
Affects Status Importance Assigned to Milestone
GNOME Settings Daemon
Unknown
Medium
gnome-settings-daemon (Ubuntu)
Confirmed
Low
Unassigned

Bug Description

After upgrading to 13.10 today, every time I unlock my computer after leaving it for a long time I get this prompt:

--

Power

Automatic suspend

Computer will suspend very soon because of inactivity.

--

However, the computer doesn't actually suspend.

And even if I do this manually (which works) and then resume, the prompt is still there (and in that case, not true at all).

This is ugly and seems broken!

As suggested by the upstream Gnome bug report, this is an issue pertaining to Ubuntu's lack of systemd integration.

ProblemType: Bug
DistroRelease: Ubuntu 13.10
Package: ubuntu-desktop 1.304
ProcVersionSignature: Ubuntu 3.11.0-8.15-generic 3.11.1
Uname: Linux 3.11.0-8-generic i686
NonfreeKernelModules: nvidia
ApportVersion: 2.12.5-0ubuntu1
Architecture: i386
Date: Sat Sep 28 15:32:42 2013
InstallationDate: Installed on 2012-08-03 (420 days ago)
InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Release i386 (20120423)
MarkForUpload: True
SourcePackage: ubuntu-meta
UpgradeStatus: Upgraded to saucy on 2013-09-28 (0 days ago)

Revision history for this message
Thomas Novin (thomasn80) wrote :
Revision history for this message
Thomas Novin (thomasn80) wrote :

Changed my settings under power in system settings, now the computer did actually suspend but still, the message should not be there IMHO after resume from suspend.

A simple notification saying the computer did suspend previously would be sufficient (or nothing at all as before 13.10).

Revision history for this message
Thomas Novin (thomasn80) wrote :

If you don't do anything about these dialogs, they stack up and become several dialogs. I had three before, this is a screenshot showing two.

Revision history for this message
Thomas Novin (thomasn80) wrote :

More craziness from this, now I have an entry in the dash but I cannot switch to this window, cannot quit it.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in ubuntu-meta (Ubuntu):
status: New → Confirmed
Revision history for this message
Ryan Press (ryan-nryiuoo) wrote :

I get the prompt too, it's annoying. On resume it should remove the notification if it's still onscreen.

Revision history for this message
Brian Murray (brian-murray) wrote :

I recreated this and while my system suspended, the message about suspending was still there upon resume.

affects: ubuntu-meta (Ubuntu) → gnome-power-manager (Ubuntu)
Thomas Novin (thomasn80)
summary: - Often automatic suspend when I unlock
+ Often automatic suspend dialog when I unlock
Revision history for this message
Thomas Novin (thomasn80) wrote : Re: Often automatic suspend dialog when I unlock

Three times in a row, after resuming from suspend I unlock the computer. Then immediately after unlock the screen goes black and then the login window again, forcing me to login yet another time.

Related or separate bug?

Revision history for this message
Tin Tvrtkovic (tinchester) wrote :

I appreciate the dialog, but it should really go away after resuming. If we can't remove it after resuming, I'd like a way to turn it off.

Also, it has no icon in the unity launcher (so displays with a big ?), which looks a little unpolished.

Revision history for this message
William Ranvaud (wiranvaud) wrote :

Or it could be like all other notifications on the top right corner with a beautiful transparency and fade away after a while.

Revision history for this message
Nick Russell (thatnick) wrote :

The new dialog seems to have been implemented in response to the following bug report: https://bugzilla.gnome.org/show_bug.cgi?id=692559

Revision history for this message
Nick Russell (thatnick) wrote :

The code to generate the dialog is in gnome-settings-daemon gsd-power-manager plugin. See: http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/saucy/gnome-settings-daemon/saucy/view/head:/plugins/power/gsd-power-manager.c#L1505

affects: gnome-power-manager (Ubuntu) → gnome-settings-daemon (Ubuntu)
Changed in gnome-settings-daemon (Ubuntu):
importance: Undecided → Low
Revision history for this message
Mike Lee (mclcorsa) wrote :

I agree - this is painful behavior. Every time I resume I need to click Cancel or OK over and over, then escape out of the the Dash (odd). Also I had turn of "Require password when waking ..." in order to avoid multiple logins (see comment #8) and make this less painful. But that leads to a less secure configuration which makes this a bit more serious problem for the broader community who might decide to take that route.

Revision history for this message
Adam Niedzielski (adamsunday) wrote :

This behaviour is extremely annoying - huge step backwards. Is there a way to revert to previous (working) version of the package?

Revision history for this message
panther_d (dk-mailbox) wrote :

Agree, and am also very interested in any way to get rid of this dialog.

I'm sorry to have to say that this dialog is one of the stupidest UI design ideas I've ever come across... :-\

Revision history for this message
Adam Niedzielski (adamsunday) wrote :

"Three times in a row, after resuming from suspend I unlock the computer. Then immediately after unlock the screen goes black and then the login window again, forcing me to login yet another time.

Related or separate bug?"

I think that it is a clash between action on suspend (Settings -> Power) and action when inactive (Settings -> Brightness & Lock). I had suspend after 5 minutes and turning off screen after 5 minutes. I believe that this was causing duplicated unlock

Revision history for this message
Arcan17 (andre-breton2006) wrote :

I agree - this is painful behavior. I would be interested in getting rid of this dialog.

Revision history for this message
GilgongoJones (gilgongo) wrote :

I have had to click my way through a stack of over 60 of these warnings today, having returned to my machine after few days during which time my cat must have woken my machine up form time to time by walking on the keyboard.

My power settings are:

Suspend on inactivity after 30 mins
Turn screen off (and lock) on inactivity after 5 mins

Revision history for this message
Furkan (falaca) wrote :

I started experiencing this after I switched from the mainline 3.11.6 kernel to the official Ubuntu-supported kernel.

Revision history for this message
kapad (rohankapadia) wrote :

Is there any option to switch off this behavior ? If not, then it need to be implemented.

Revision history for this message
caprico (caprico4) wrote :

Since ever it became normal for Ubuntu to, with every new release, make 1 step forward but 3 steps back, this is probably the most annoying step backwards. Really annoying!!! I don't even know why such a message is needed, doesn't make any sense at all. Please fix NOW.

Revision history for this message
Thomas Novin (thomasn80) wrote :

Really agree with comment above.

"Sebastien Bacher (seb128) on 2013-10-23
Changed in gnome-settings-daemon (Ubuntu):
importance: Undecided → Low"

@seb128 Can you please explain why you feel this is of "Low" importance?

Changed in gnome-settings-daemon:
importance: Unknown → Medium
status: Unknown → Incomplete
Revision history for this message
GwaiTsi (gwaitsi) wrote :

add me to the voice of frustration. It wouldn't be so bad if;
- the dialog didn't appear as many as five times
- after entering the password to login, clicking on the dialog caused it to revert back to the login screen and having to re-login again.

i could think of a few profanities to describe this behavior and the genius who thought to add it,
but i'm sure it was meant with the best intent.

Revision history for this message
Greg Michalec (greg-primate) wrote : Re: [Bug 1232454] Re: Often automatic suspend dialog when I unlock

It appears based on the gnome bug report
(https://bugzilla.gnome.org/show_bug.cgi?id=712176) that the dialog is
meant to be removed upon resuming. to quote:

"I see that the notification is getting removed when resuming already,
so it's probably something to do with Ubuntu's non-use of systemd/logind."

On 11/18/2013 11:36 AM, GwaiTsi wrote:
> add me to the voice of frustration. It wouldn't be so bad if;
> - the dialog didn't appear as many as five times
> - after entering the password to login, clicking on the dialog caused it to revert back to the login screen and having to re-login again.
>
> i could think of a few profanities to describe this behavior and the genius who thought to add it,
> but i'm sure it was meant with the best intent.
>

Cas (calumlind)
summary: - Often automatic suspend dialog when I unlock
+ "Computer will suspend very soon because of inactivity." dialog when
+ resuming from suspend
Changed in gnome-settings-daemon:
status: Incomplete → Unknown
Revision history for this message
VQ35 (vq35power) wrote :

I have my laptop set to Auto Suspend. It used to work flawlessly but now due to this dialog box, the system will not suspend automatically until I okay or cancel it out. It is really annoying and the notification dialog should be removed please!

Revision history for this message
Roger James (rogerjames99) wrote :

I think there are a number of bugs here.

The version I see is.

With "Turn screen off when inactive set to 30 minutes" and "Suspend when inactive for" set to 1 hour. If I come back after an hour the screen has turned off, but the computer has not suspended. When I wake up the screen the dekstop has locked as expected, when I type in my password the dekstop unlocks and shows the "Computer will suspend very soon because of inactivity." dialog.

This bug should probably be more like "Computer will suspend very soon because of inactivity." dialog prevents system from suspending.

I will call the the Type A version of this bug. I think it the same as Bug #1243174 which is marked as a duplicate of this.

Does any one who sees them want to define types B,C, and D!

Revision history for this message
Dimitri John Ledkov (xnox) wrote :

On ubuntu, "ok" "cancel" are useless, instead actions should be dropped, and at most a bubble (notify-osd) be shown.

description: updated
Revision history for this message
Amos Blanton (lightnin9) wrote :

Please remove this dialog box. It serves no useful purpose, and is a great annoyance.
It would be useful to have a designer review decisions about spurious dialog boxes like this before adding them.

Revision history for this message
Bib (bybeu) wrote :

Append

if [ -f ~/.myscripts ]; then
. ~/.myscripts
fi

at the end of ~/.bashrc.
Copy the attachment in ~
mv myscripts .myscripts
chmod +x .myscripts
logout/login

Revision history for this message
Bib (bybeu) wrote :

Please note:
I) You need to install wmctrl
II) Then adapt to your language:
in the script, change
nergie in the line below
then NumWarn=`wmctrl -l | grep 'nergie' | wc -l`
to the title of the warning popup in your language

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "monitors dbus for screen saver unlock then killall notify-osd" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Revision history for this message
Bib (bybeu) wrote :

Here is a workaround that doesn't need wmctrl and is locale insensitive
Append

if [ -f ~/.myscripts ]; then
. ~/.myscripts
fi

at the end of ~/.bashrc.
Copy the attachment in ~
mv myscripts .myscripts
chmod +x .myscripts
logout/login

Revision history for this message
ChemDroid (waoig-public-deactivatedaccount) wrote :

Thanks for your workaround, Bib.

I tested it yesterday and unfortunately it doesn't work reliably. Especially after rebooting it's not working for me unless I logout and login again.
I found a much more convenient solution based on the hooks of pm-utils, so it's also independent of your screensaver settings.

Simply copy the attachement (20_kill-notify-osd) to /etc/pm/sleep.d:

sudo mv 20_kill-notify-osd /etc/pm/sleep.d
sudo chmod +x /etc/pm/sleep.d/20_kill-notify-osd

Revision history for this message
Bib (bybeu) wrote :

Far more beautiful and lighter ! :)
Does it also work from thaw?

Revision history for this message
ChemDroid (waoig-public-deactivatedaccount) wrote :

It should also work from thaw. You only have to change the line

resume)

to

resume|thaw)

Revision history for this message
Chris (chris-m-ger) wrote :

In my case it works if I also "kill" the notification-daemon (I'm also using 13.10. but I'm not sure if I didn't messed up my notifications once).
I'm not an expert in scripting. However it works.

Regards

Revision history for this message
Carsten Schnober (carscht) wrote :

Thanks for the suggestions. I'd like to point out, however, that automatically killing the notification windows affects any notification, including ones that might indicate completely unrelated issues. I suppose this could result in quite annoying effects when potentially important messages are dismissed through this. Therefore I would not even consider this approach a workaround for the actual problem.
There might be a way to kill specific notification windows only, but I don't think that this leads to a clean solution for the bug either.

Revision history for this message
Bib (bybeu) wrote :

@ChemDroid
I just understand your way to do won't kill the silly popup when you unlock the session just between the moment when the popup araises and the moment when the pc goes to sleep.
It seems to me that the best killer trigger remains the moment when we enter the password.
Assumed Carsten comment, I think I'll switch back to the use of wmctrl which seems to target more precisely the "Energy" pop-up, although I'm completely ignorant and unskilled if this window title is used elsewhere.
I tried here ( https://forum.ubuntu-fr.org/viewtopic.php?pid=15709961#p15709961 ) to use wmctrl -ci 0x..... but I had bad behaviour, wmctrl killed other windows when it didn't find the exact win id.......

https://bugs.launchpad.net/ubuntu/+source/wmctrl/+bug/1266273 shows either a real bug in wmctrl or just that I'm a real newb patcher.

Revision history for this message
Bib (bybeu) wrote :

So I'm back with the way with wmctrl (I found why it didn't work fine: wmctrl requires OPTIONS to be passed before ACTIONS)
In the patch below, replace "Énergie" with the title of the popup in your language.

Revision history for this message
pdknsk (pdknsk) wrote :

IMO there are three separate bugs here.

The first bug is the dialog itself. Why is there such a dialog? It's not necessary.
The second bug is that the dialog sometimes prevents suspend from working.
And the third bug is the dialog not closing itself when the system resumes. This is merely cosmetic but makes Ubuntu look amateurish.

The easiest solution is to completely remove the dialog.

Revision history for this message
Carsten Schnober (c-schnober) wrote :

I second pdknsk's suggestion. There might be some rare situation in which a notification before going to sleep could be helpful, but in a typical scenario, being inactive implies that a user is not watching the screen anyway.
On the other hand, I suppose that users that are silently reading on the screen would actually be pleased by a notification. Having them in mind, I would suggest to replace the notification window with an onscreen message through empathy.

Revision history for this message
Ray Velez (ray-velez) wrote :

One way to alleviate the problem of the power 'notify' dialog box is to access under 'system settings' the 'Brightness & Lock' function. There disable the 'Lock screen after' function and the next time your system is awakened from suspend mode the 'notify' dialog is no longer.

Revision history for this message
Carsten Schnober (carscht) wrote :

Unfortunately, this does not make a difference for me, the dialog keeps appearing...

Revision history for this message
Bib (bybeu) wrote :

@ Ray Velez , I feel this is not a satisfying solution (I didn't try) because it is like a weakness in security settings.

My script is not working well: although it works fine as long as the computer don't ends in sleep, when sleep happens then on resume then login the script won't do the job. I can't find why.
Inactive->ScreenOff->Lock->Notify->Sleep->Resume->Login->KO (popup remains)
Inactive->ScreenOff->Lock->Notify->Login->OK (close popup)

Revision history for this message
Bachi (m-bachmann) wrote :

I would love to have a word with the developer of this feature and I wonder how this went through QA. It's so obviously broken that it looks like the "feature" was never tested. And I also wonder what takes so long to just remove the unwanted "feature".
(sorry, but such silly things are annoying - and would be easy to circumvent with the proper QA process)

Revision history for this message
Bachi (m-bachmann) wrote :
Revision history for this message
hcbdhattem (hardcorebarbiedoll) wrote :

NotifyOSD has a fallback to alertbox function and maybe this is being called in stead of a normal notification.

More info here: https://wiki.ubuntu.com/NotifyOSD#Fallback_alert_boxes
The first lines read: "For cases where applications have expected the notification system to allow interactivity without checking whether it actually does, and cases where applications have expected the notification system to display a notification indefinitely, Notify OSD should show an alert box as a fallback."

Revision history for this message
Bib (bybeu) wrote :

Sorry, I give up

Revision history for this message
futwick (futwick) wrote :

Does anyone know if this bug remains in 14.04? If so I suggest it adding it to the One Hundred Papercuts project.

https://launchpad.net/hundredpapercuts
"Papercuts are easily fixable but very annoying bugs."

Revision history for this message
Bib (bybeu) wrote :
Revision history for this message
Nicolas Michel (be-nicolas-michel) wrote :

Hey guys, go to the mentionned link : https://bugs.launchpad.net/hundredpapercuts/+bug/1296895
And click on the top of the page to say it also affects you: "This bug affects you and 2 other people".

I'm also hit by the bug although I'm on a TOWER and have no battery in it ...

Revision history for this message
Carsten Schnober (c-schnober) wrote :

I'm happy to see that this bug has been more or less resolved in 14.04 by changing the dialog to a less intrusive notification.

Revision history for this message
Sal Mazzola (salmaz) wrote :

I found a fix that worked for me to restore autosuspend. See this bug on gnome-shell (where the fix is required).

https://bugs.launchpad.net/ubuntu/+source/gnome-shell/+bug/1345116

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.