• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Alan-Jowett / sonde / 24618764992
82%

Build:
DEFAULT BRANCH: main
Ran 19 Apr 2026 02:12AM UTC
Jobs 1
Files 113
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

19 Apr 2026 02:08AM UTC coverage: 80.751% (-0.1%) from 80.859%
24618764992

push

github

web-flow
fix(gateway): re-send SET_CHANNEL after modem warm reboot (GW-1103) (#762)

* fix(gateway): re-send SET_CHANNEL to modem after warm reboot (GW-1103)

When the modem firmware warm-reboots (USB CDC stays open), the reader
task received an unexpected \MODEM_READY\ and discarded it. The modem
returns to channel 1 on reset, but the gateway was not re-running the
startup sequence.

Changes:
- modem.rs: unexpected \MODEM_READY\ now cancels all pending waiters,
  sets \warm_reboot_flag\ (AtomicBool), and fires \warm_reboot_notify\
  (Notify). Adds \bort_reader_and_wait()\ to allow the gateway to
  await the reader task before reopening the port.
- ble_pairing.rs: \BlePairingController\ gains \vent_task\ storage,
  \set_event_task()\, and \cancel_and_wait()\ to ensure the
  \open_ble_pairing\ detached task releases its \Arc<transport>\.
- admin.rs: stores the event-forwarding task handle on the controller;
  \close_ble_pairing\ uses \cancel_and_wait()\.
- gateway.rs: \select!\ gains a \warm_reboot_notify.notified()\ arm;
  after \select!\, checks \warm_reboot_flag\ and if set: cancels the
  BLE session, aborts consumer tasks, awaits the reader task
  (\bort_reader_and_wait\) to release the serial port read half,
  drops the transport, then \continue\s without backoff sleep.
- Tests: T-1104d verifies unexpected MODEM_READY fires the notify,
  sets the flag, and cancels a pending \change_channel\ waiter.

Backoff is reset to 1 s on any successful transport creation (existing
behavior), so warm-reboot reconnects proceed immediately.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* fix(gateway): address PR 762 round-2 review comments

- ble_pairing: cancel_and_wait() now uses a 500ms timeout + abort_handle
  fallback so warm-reboot recovery cannot hang if the event-forwarding
  task is blocked on a full mpsc channel (comment 6)
- gateway: abort all tasks (frame_loop, ble_loop, grpc_handle,
  health_handle) on the normal disconnect path b... (continued)

70 of 130 new or added lines in 4 files covered. (53.85%)

6 existing lines in 2 files now uncovered.

24420 of 30241 relevant lines covered (80.75%)

203.67 hits per line

Uncovered Changes

Lines Coverage ∆ File
50
0.0
0.0% crates/sonde-gateway/src/bin/gateway.rs
5
83.75
-3.01% crates/sonde-gateway/src/ble_pairing.rs
5
77.79
1.35% crates/sonde-gateway/src/modem.rs

Coverage Regressions

Lines Coverage ∆ File
5
83.75
-3.01% crates/sonde-gateway/src/ble_pairing.rs
1
0.0
0.0% crates/sonde-gateway/src/bin/gateway.rs
Jobs
ID Job ID Ran Files Coverage
1 24618764992.1 19 Apr 2026 02:12AM UTC 113
80.75
GitHub Action Run
Source Files on build 24618764992
  • Tree
  • List 113
  • Changed 4
  • Source Changed 4
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #24618764992
  • f23048f4 on github
  • Prev Build on main (#24615722129)
  • Next Build on main (#24623983217)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc