Skip to content

*: detecting abrupt disconnections in Linux#408

Open
sorayaormazabalmayo wants to merge 1 commit intotinygo-org:devfrom
sorayaormazabalmayo:feature/abrupt-disconnection-linux
Open

*: detecting abrupt disconnections in Linux#408
sorayaormazabalmayo wants to merge 1 commit intotinygo-org:devfrom
sorayaormazabalmayo:feature/abrupt-disconnection-linux

Conversation

@sorayaormazabalmayo
Copy link

This PR implements persistent D-Bus signal monitoring at the adapter level to detect abrupt disconnections. The connectHandler callback was not being invoked when Bluetooth devices disconnected abruptly (e.g., device powered off, out of range, battery died) on Linux. It only worked for planned disconnections via Device.Disconnect(). This created an inconsistency with the Darwin implementation, which correctly detects all disconnections through CoreBluetooth's DidDisconnectPeripheral delegate method.

@deadprogram deadprogram changed the base branch from release to dev February 10, 2026 11:40
@sorayaormazabalmayo sorayaormazabalmayo force-pushed the feature/abrupt-disconnection-linux branch from 910d2c2 to 904e54e Compare February 11, 2026 10:52
This PR implements persistent D-Bus signal monitoring at the adapter
level to detect abrupt disconnections. The `connectHandler` callback was
not being invoked when Bluetooth devices disconnected abruptly (e.g.,
device powered off, out of range, battery died) on Linux. It only worked
for planned disconnections via `Device.Disconnect()`. This created an
inconsistency with the Darwin implementation, which correctly detects
all disconnections through CoreBluetooth's `DidDisconnectPeripheral`
delegate method.
@sorayaormazabalmayo sorayaormazabalmayo force-pushed the feature/abrupt-disconnection-linux branch from 904e54e to 2818558 Compare February 11, 2026 11:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant