After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 747887 - No power-management notifications are displayed
No power-management notifications are displayed
Status: RESOLVED NOTGNOME
Product: gnome-settings-daemon
Classification: Core
Component: power
3.16.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-settings-daemon-maint
gnome-settings-daemon-maint
Depends on:
Blocks:
 
 
Reported: 2015-04-15 06:01 UTC by Bastián Díaz
Modified: 2016-07-26 09:57 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Screenshots (175.93 KB, application/x-7z-compressed)
2016-07-25 15:52 UTC, Bastián Díaz
Details

Description Bastián Díaz 2015-04-15 06:01:26 UTC
Notifications power management are not displayed (low battery, AC connected, etc)

Further options do not appear in the notification panel in the control center.

Tested in: Fedora (22) rawhide, Gnome 3.16
Laptop: Acer Aspire ES1-111M

Thanks
Comment 1 Bastián Díaz 2015-10-31 17:14:27 UTC
Hi, this bug remains at 3.18.

Is it by design, or it is proposed that the energy notifications back?


Cheers
Comment 2 Bastien Nocera 2016-07-22 13:08:57 UTC
There are notifications, have always been. Did you per-chance disable the notifications in the notifications panel.
Comment 3 Bastien Nocera 2016-07-22 13:10:02 UTC
(Assigning this to a dead component isn't going to help people see your bug reports. gnome-power-manager only contains a viewer to analyse battery consumption over time).
Comment 4 Bastián Díaz 2016-07-22 14:20:15 UTC
(In reply to Bastien Nocera from comment #3)
> (Assigning this to a dead component isn't going to help people see your bug
> reports. gnome-power-manager only contains a viewer to analyse battery
> consumption over time).

Ok, sorry.
Comment 5 Bastián Díaz 2016-07-22 14:36:50 UTC
(In reply to Bastien Nocera from comment #2)
> There are notifications, have always been. Did you per-chance disable the
> notifications in the notifications panel.

No, nothing appears related to energy in the notification panel.
Comment 6 Florian Müllner 2016-07-22 15:09:39 UTC
Did you maybe disable gnome-settings-daemon's power plugin?
Comment 7 Bastián Díaz 2016-07-22 20:53:24 UTC
(In reply to Florian Müllner from comment #6)
> Did you maybe disable gnome-settings-daemon's power plugin?

The plugin is enabled. Even at that time I did a clean install of fedora 23 and power notifications were missing. ¿fedora issue maybe?
Comment 8 Bastien Nocera 2016-07-22 21:56:23 UTC
OK, so instead of looking at a setup problem, and seeing as this is the only report I ever had about notifications being missing, maybe it's a different problem.

When do you expect to see power notifications and not see them?
When you would expect to see a notification and none is showing, what's the output of:
upower -i /org/freedesktop/UPower/devices/DisplayDevice

We only show notifications on low and very low battery levels, and when the mains power has been removed but a UPS is present.
Comment 9 Bastián Díaz 2016-07-23 10:44:21 UTC
(In reply to Bastien Nocera from comment #8)
> OK, so instead of looking at a setup problem, and seeing as this is the only
> report I ever had about notifications being missing, maybe it's a different
> problem.
> 

It seemed strange, but as I said in another message to perform a clean installation the issue persists.

> When do you expect to see power notifications and not see them?

When connecting/disconnecting the power source, low and critical battery levels...

> When you would expect to see a notification and none is showing, what's the
> output of:
> upower -i /org/freedesktop/UPower/devices/DisplayDevice
> 

power supply:         yes
  updated:              sáb 23 jul 2016 03:56:18 CLT (64 seconds ago)
  has history:          no
  has statistics:       no
  battery
    present:             yes
    state:               discharging
    warning-level:       none
    energy:              30,0276 Wh
    energy-full:         31,2018 Wh
    energy-rate:         6,2586 W
    time to empty:       4,8 hour
    percentage:          96%
    icon-name:          'battery-full-symbolic'

> We only show notifications on low and very low battery levels, and when the
> mains power has been removed but a UPS is present.

I realized the problem when my laptop reaches the critical energy level without receiving any notification and shutting down.
Comment 10 Florian Müllner 2016-07-23 12:34:15 UTC
(In reply to Bastián Díaz from comment #9)
>     time to empty:       4,8 hour
>     percentage:          96%
>     icon-name:          'battery-full-symbolic'

So UPower tells us that the battery is (close to) fully charged ...
Comment 11 Bastián Díaz 2016-07-23 13:03:29 UTC
(In reply to Florian Müllner from comment #10)
> (In reply to Bastián Díaz from comment #9)
> >     time to empty:       4,8 hour
> >     percentage:          96%
> >     icon-name:          'battery-full-symbolic'
> 
> So UPower tells us that the battery is (close to) fully charged ...

Oh, sorry ... I was a little late at night and I now understand well what was the question...
Comment 12 Bastián Díaz 2016-07-24 01:39:54 UTC
Is supposed to a notification "low battery" should appear when there is a 10% battery (upower default config).

====
  power supply:         yes
  updated:              sáb 23 jul 2016 18:17:38 CLT (8 seconds ago)
  has history:          no
  has statistics:       no
  battery
    present:             yes
    state:               discharging
    warning-level:       none
    energy:              2,7702 Wh
    energy-full:         25,5246 Wh
    energy-rate:         7,3986 W
    time to empty:       22,5 minutes
    percentage:          10%
    icon-name:          'battery-low-symbolic'
====

Upower config (extract)
====
# Policy for warnings and action based on battery levels
#
# Whether battery percentage based policy should be used. The default
# is to use the time left, change to true to use the percentage, which
# should work around broken firmwares. It is also more reliable than
# the time left (frantically saving all your files is going to use more
# battery than letting it rest for example).
# default=true
UsePercentageForPolicy=true

# When UsePercentageForPolicy is true, the levels at which UPower will
# consider the battery low, critical, or take action for the critical
# battery level.
#
# This will also be used for batteries which don't have time information
# such as that of peripherals.
#
# If any value is invalid, or not in descending order, the defaults
# will be used.
#
# Defaults:
# PercentageLow=10
# PercentageCritical=3
# PercentageAction=2
PercentageLow=10
PercentageCritical=3
PercentageAction=2
====

I have no energy section in the notifications panel (gnome control center).
Comment 13 Bastien Nocera 2016-07-24 07:09:33 UTC
(In reply to Bastián Díaz from comment #12)
> Is supposed to a notification "low battery" should appear when there is a
> 10% battery (upower default config).

You still have more than 10%. 10.64% to be exact.
Comment 14 Bastián Díaz 2016-07-24 16:24:45 UTC
(In reply to Bastien Nocera from comment #13)
> (In reply to Bastián Díaz from comment #12)
> > Is supposed to a notification "low battery" should appear when there is a
> > 10% battery (upower default config).
> 
> You still have more than 10%. 10.64% to be exact.
 
You say that the percentage should be 10.0% to be notified? I do not remember work that way. Anyway I waited for 3% critical battery notification. Nothing happened...

The warning-level should indicate "low" (10%) and "very low" (3%) keyword, right?

I only get a hardware indicator (led) when the battery is 15%.
Comment 15 Bastien Nocera 2016-07-24 19:40:14 UTC
(In reply to Bastián Díaz from comment #14)
> (In reply to Bastien Nocera from comment #13)
> > (In reply to Bastián Díaz from comment #12)
> > > Is supposed to a notification "low battery" should appear when there is a
> > > 10% battery (upower default config).
> > 
> > You still have more than 10%. 10.64% to be exact.
>  
> You say that the percentage should be 10.0% to be notified? I do not
> remember work that way. Anyway I waited for 3% critical battery
> notification. Nothing happened...

Can I have that "upower -d" output then?

> The warning-level should indicate "low" (10%) and "very low" (3%) keyword,
> right?

Yes.
Comment 16 Bastián Díaz 2016-07-25 10:15:08 UTC
(In reply to Bastien Nocera from comment #15)
> (In reply to Bastián Díaz from comment #14)
> > (In reply to Bastien Nocera from comment #13)
> > > (In reply to Bastián Díaz from comment #12)
> > > > Is supposed to a notification "low battery" should appear when there is a
> > > > 10% battery (upower default config).
> > > 
> > > You still have more than 10%. 10.64% to be exact.
> >  
> > You say that the percentage should be 10.0% to be notified? I do not
> > remember work that way. Anyway I waited for 3% critical battery
> > notification. Nothing happened...
> 
> Can I have that "upower -d" output then?
> 

Device: /org/freedesktop/UPower/devices/line_power_ACAD
  native-path:          ACAD
  power supply:         yes
  updated:              dom 24 jul 2016 23:09:57 CLT (5141 seconds ago)
  has history:          no
  has statistics:       no
  line-power
    warning-level:       none
    online:              no
    icon-name:          'ac-adapter-symbolic'

Device: /org/freedesktop/UPower/devices/battery_BAT1
  native-path:          BAT1
  vendor:               LGC
  model:                AC14B18J
  serial:               20387
  power supply:         yes
  updated:              lun 25 jul 2016 00:35:08 CLT (30 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               discharging
    warning-level:       none
    energy:              3,0438 Wh
    energy-empty:        0 Wh
    energy-full:         28,9446 Wh
    energy-full-design:  36,708 Wh
    energy-rate:         5,5974 W
    voltage:             10,017 V
    time to empty:       32,6 minutes
    percentage:          10%
    capacity:            78,8509%
    technology:          lithium-ion
    icon-name:          'battery-low-symbolic'
  History (charge):
    1469421248	10,000	discharging
  History (rate):
    1469421308	5,597	discharging
    1469421278	3,374	discharging
    1469421248	5,438	discharging

Device: /org/freedesktop/UPower/devices/DisplayDevice
  power supply:         yes
  updated:              lun 25 jul 2016 00:35:08 CLT (30 seconds ago)
  has history:          no
  has statistics:       no
  battery
    present:             yes
    state:               discharging
    warning-level:       none
    energy:              3,0438 Wh
    energy-full:         28,9446 Wh
    energy-rate:         5,5974 W
    time to empty:       32,6 minutes
    percentage:          10%
    icon-name:          'battery-low-symbolic'

Daemon:
  daemon-version:  0.99.4
  on-battery:      yes
  lid-is-closed:   no
  lid-is-present:  yes
  critical-action: PowerOff
Comment 17 Bastien Nocera 2016-07-25 11:48:11 UTC
3,0438 Wh / 28,9446 Wh = 0.105159512 = 10.5%

Could you please run "upower -d" when the percentage is *lower* than 10%?
Could you please also take a picture of the status icon menu when at that percentage?
Comment 18 Bastián Díaz 2016-07-25 15:52:04 UTC
Created attachment 332108 [details]
Screenshots
Comment 19 Bastien Nocera 2016-07-26 09:57:35 UTC
It's a bug (or misconfiguration) in UPower. The warning level should have been set. Please file a bug at freedesktop.org against UPower.