Bug 469692

Summary: My mouse is presented as keyboard in battery status
Product: [Applications] kinfocenter Reporter: Andrew Shark <ashark>
Component: generalAssignee: Plasma Bugs List <plasma-bugs>
Status: RESOLVED UPSTREAM    
Severity: normal CC: nicolas.fella, sitter
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: Ambiguous notification screenshot
Mouse presented as keyboard in Info center energy tab

Description Andrew Shark 2023-05-13 08:42:51 UTC
Created attachment 158904 [details]
Ambiguous notification screenshot

I have the wireless mouse - Logitech MX Master. And also a wireless logitech keyboard.
I have notification, saying "Keyboard Battery Low" several times when I start working (mouse wakes from sleep). After some time of working my mouse suddenly turned off because discharged. Such situation repeated several times.

And now I realize that the message was actually about my mouse. In the notification _body_ I see it is saying my _mouse_ is running low. See screenshot.

STEPS TO REPRODUCE
1. Discharge your mouse to low level
2. Dont move it for a while, allowing it to go to sleep
3. Move the mouse.

OBSERVED RESULT
You get a notification titled "Keyboard Battery Low" and with keyboard icon.

EXPECTED RESULT
You should get a notification titled "Mouse Battery Low" with mouse icon.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.27.5
KDE Frameworks Version: 5.105.0
Qt Version: 5.15.9
Graphics Platform: Wayland
Info Center: 5.27.5
Comment 1 Andrew Shark 2023-05-13 08:44:38 UTC
Created attachment 158905 [details]
Mouse presented as keyboard in Info center energy tab
Comment 2 Nicolas Fella 2023-05-13 09:51:58 UTC
Please run "upower -d" and paste the output here
Comment 3 Andrew Shark 2023-05-13 10:35:07 UTC
$ upower -d
Device: /org/freedesktop/UPower/devices/battery_hidpp_battery_0
  native-path:          hidpp_battery_0
  model:                K850 PerformanceK850 PerformanceK8
  serial:               4062-1c-ed-6e-11
  power supply:         no
  updated:              Сб 13 мая 2023 13:32:05 (4 seconds ago)
  has history:          yes
  has statistics:       yes
  keyboard
    present:             yes
    rechargeable:        yes
    state:               fully-charged
    warning-level:       none
    battery-level:       full
    percentage:          100% (should be ignored)
    icon-name:          'battery-full-charged-symbolic'
  History (charge):
    1683973925  100,000 fully-charged

Device: /org/freedesktop/UPower/devices/battery_hidpp_battery_1
  native-path:          hidpp_battery_1
  model:                Wireless Mouse MWireless
  serial:               4060-a5-2f-8a-b0
  power supply:         no
  updated:              Сб 13 мая 2023 13:31:43 (26 seconds ago)
  has history:          yes
  has statistics:       yes
  keyboard
    present:             yes
    rechargeable:        yes
    state:               discharging
    warning-level:       critical
    battery-level:       critical
    percentage:          5% (should be ignored)
    icon-name:          'battery-caution-symbolic'

Device: /org/freedesktop/UPower/devices/DisplayDevice
  power supply:         no
  updated:              Сб 13 мая 2023 04:45:27 (31602 seconds ago)
  has history:          no
  has statistics:       no
  unknown
    warning-level:       none
    percentage:          0%
    icon-name:          'battery-missing-symbolic'

Daemon:
  daemon-version:  1.90.0
  on-battery:      no
  lid-is-closed:   no
  lid-is-present:  no
  critical-action: PowerOff
Comment 4 Nicolas Fella 2023-05-13 10:57:56 UTC
upower reports the mouse as a keyboard, there's not much we can do about that.

See https://gitlab.freedesktop.org/upower/upower/-/issues/215