Cinnamon Power Applet does not refresh wireless battery devices when their availability or state changes
@mtwebster đang làm issue này rồi.
Từ ngày 30/11/2026.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- javascript, linux
- Lĩnh vực
- desktop
Hướng nghiên cứu
The issue identifies [email protected]/applet.js and includes a tested patch in the attached archive. Start by reviewing that patch and the reported UPower signal behavior; check how the applet refreshes devices and manages signal subscriptions and timers. Done means the battery list updates as devices appear, disappear, or change relevant properties, with the reported connection and resume scenarios working.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Environment
- Linux Mint 27 "Adrien" Beta – Cinnamon Edition
- Cinnamon: 6.8.4+mint27
- Cinnamon Settings Daemon: 6.8.2+mint27
- Session: Wayland
- Laptop: Dell XPS 13 9340
- Kernel: 7.3.0-1004-oem
- UPower: 1.91.1-1+logitech1
- Mouse: Logitech MX Anywhere 3S
- Keyboard: Logitech MX Keys Mini
Note: My system uses locally modified Logitech HID++ kernel modules and UPower for improved Logitech Bolt battery reporting. However, both UPower and Cinnamon Settings Daemon report the correct battery information in the tests described below.
Description
After starting the computer with both wireless devices switched on, I noticed that my mouse was missing from the Cinnamon Power Applet's battery list.
The keyboard was displayed correctly, and the mouse and its correct battery percentage were visible under Power Settings → Batteries.
Enabling and disabling panel edit mode immediately restored the missing mouse entry.
Further investigation
Monitoring UPower and Cinnamon Settings Daemon simultaneously revealed that UPower correctly emits PropertiesChanged signals when the mouse is switched off or on:
- Mouse switched off: State = 0 (Unknown).
- Mouse switched on: State = 2 (Discharging).
However, no corresponding change notification was observed from org.cinnamon.SettingsDaemon.Power during this test.
Calling the GetDevices method directly confirmed that Cinnamon Settings Daemon already had the correct device state and battery percentage.
The Power Applet therefore appears to retain an outdated device list until another event triggers a refresh.
Expected behaviour
The Power Applet should automatically update when battery-powered devices become available or unavailable, or when their relevant battery properties change.
Proposed fix
I prepared and tested a patch for [email protected]/applet.js that:
- Subscribes directly to UPower DeviceAdded and DeviceRemoved signals.
- Listens for relevant UPower device property changes.
- Ignores timestamp-only updates.
- Coalesces refresh requests within a 200 ms interval.
- Guards against outdated asynchronous responses.
- Cleans up signal subscriptions and pending refresh timers when the applet is removed.
The existing Cinnamon Settings Daemon integration is retained.
No continuous polling or additional background service is required.
Test results
After applying the patch, all of the following tests passed:
- Logitech MX Anywhere 3S connected via Bolt: switching off and on.
- Logitech MX Anywhere 3S connected via Bluetooth: switching off and on.
- Logitech MX Keys Mini connected via Bolt: switching off and on.
- Hibernation and resume.
- Rebooting with the mouse switched on.
- Rebooting with the mouse switched off, then switching it on after login.
- Physically disconnecting and reconnecting the Bolt USB receiver.
Devices now disappear and reappear in the battery menu almost immediately when their availability changes.
No relevant JavaScript errors or warnings were found in the journal for the latest boot.
The patch is not Logitech-specific and uses standard UPower D-Bus signals.
Additional information
The attached archive contains the tested patch and supporting diagnostic evidence.
I have not yet reproduced the issue on a completely unmodified Mint installation, tested the patch under X11, or performed long-term performance testing.
I hope this can be reviewed for inclusion in Cinnamon before the final Linux Mint 27 release.
Thank you for your work on Linux Mint and Cinnamon!
- Ngôn ngữ chính
- Không có dữ liệu ngôn ngữ
- Star
- 10
- Fork
- 1
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của linuxmint/mint27-beta
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 66/100
linuxmint/mint27-beta#151 · 1 bình luận ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 48/100
linuxmint/mint27-beta#154 ·
-
Algunas herramientas de "administracion del sistema" no siguen el tema global "oscuro" del sistema.Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 43/100
linuxmint/mint27-beta#150 ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 48/100
linuxmint/mint27-beta#149 · 2 bình luận ·
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
linuxmint/mint27-beta#145 ·
Tất cả issue của linuxmint/mint27-beta
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày
-
OpenCode 2.x: Go quota shows "Sign in again" because the API key is read only from auth.jsonĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Javis603/token-monitor#1861 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
macos-27 menubar punkto regression
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
thaw-app/Thaw#1791 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[2.5.4] 设为「不写日报」后,值班提示词仍要求写日报Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
c1overzz/dsh-bili-scroll#216 ·
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
omacom/omarchy#21787 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày