Public bug reported: solaar 1.1.19 in 26.04 raises AssertionError in _device_row() when a directly connected (Bluetooth) device is removed or unpaired. The process survives: the exception is raised in a GLib idle callback, PyGObject hands it to sys.excepthook, and apport files a crash report. The rest of the status update is skipped, so the stale device row is not removed, the diversion rules are not refreshed, and every later status change files another report.
Error tracker: https://errors.ubuntu.com/problem/8e9bb82e4d42a3f1f44bb04144a58448fe842392 Signature: /usr/bin/solaar:AssertionError:_status_changed:update:_device_row 234 reports/week on 26.04 (a floor: 93/200 sampled incidents have no DistroRelease). 189/200 samples are 1.1.19-1; the rest are 1.1.16-1.1.19 PPA builds. Trace: solaar/ui/__init__.py:135 _status_changed -> window.update() -> window.py:870 _device_row(path, ...) -> window.py:423 assert receiver_path == Cause == window.update() computes path = device.receiver.path if device.receiver is not None else device.path and passes it to _device_row(), which starts with assert receiver_path. When a device is unpaired, the listener replaces it with a ghost whose path is None (listener.py:62-65). For a receiver-backed device the receiver path is used, so the assert passes; for a direct-connected device receiver is None, so path is None and the assert fires. == Fix == Upstream 97311bed5fa9c5f127ceeb0a811f69a43923162a ("ui: handle missing receiver_path more gracefully", Peter F. Patel-Schneider), merged as https://github.com/pwr-Solaar/Solaar/pull/3095 on 2026-01-08. It replaces the assert with: if receiver_path is None: return None First released in 1.1.20rc2 (2026-05-12) and 1.1.20 (2026-06-28). The 1.1.19 tag was cut 11 minutes before the merge and does not contain it; no backport branch exists. The attached patch is the window.py hunk of that commit (the docs hunk is omitted) with DEP-3 headers. == Verification == survey/solaar/repro_update.py builds a fake direct-connected device (receiver=None, path=None, number=0xFF) and calls window.update() with stubbed _window/_tree and a pyudev stub. Unpatched 1.1.19-1: exit 3, AssertionError at window.py:423, reached from window.py:870 - the same frames as the report. Patched 1.1.19-1: exit 0, update() returns normally. 1.1.20: exit 0. The GTK tree view is not exercised (no display), so row removal itself is not tested; the assert/return path is exactly the reported one and needs no hardware. == SRU == Only 26.04 needs this: 26.10 ships 1.1.20-2 and 27.04 1.1.20-3, both with the upstream guard. A targeted backport is appropriate; syncing all of 1.1.20 is not (no microrelease exception, large delta). Proposed: 1.1.19-1ubuntu0.1. Risk is very low: the patch removes an assert and returns None, already the documented behaviour for a missing path, and has been in upstream releases since May 2026. == Test plan == 1. On 26.04 with solaar 1.1.19-1, unpair or remove a directly connected (Bluetooth) device. Observe the AssertionError traceback and a new apport report; the stale row remains. 2. With 1.1.19-1ubuntu0.1, repeat: the row disappears, the diversion rules refresh, and no report is filed. 3. Error tracker: the bucket should fall to zero after release. ** Affects: solaar (Ubuntu) Importance: Medium Status: In Progress ** Affects: solaar (Ubuntu Resolute) Importance: Medium Status: In Progress ** Tags: desktop-needs-sru resolute -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2190906 Title: solaar 1.1.19: AssertionError on device removal with no receiver path To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/solaar/+bug/2190906/+subscriptions -- ubuntu-bugs mailing list [email protected] https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
