Skip to content

fix(wifi): port the provisioning, retry, and splash train from litclock-dev - #50

Merged
kapoorankush merged 1 commit into
masterfrom
feat/port-wifi-provisioning-train
Aug 12, 2026
Merged

fix(wifi): port the provisioning, retry, and splash train from litclock-dev#50
kapoorankush merged 1 commit into
masterfrom
feat/port-wifi-provisioning-train

Conversation

@kapoorankush

Copy link
Copy Markdown
Owner

File-level port of the wifi/provisioning seam of the litclock-dev #606-#631 train into the public repo. The companion PR ports the rest of the train; the two are file-disjoint and merge in either order.

What ships (dev PRs folded here)

  • litclock-dev#630 + #616: a reused profile's PSK survives a failed connect. #630 is the working form (the #616 snapshot listing is rejected by real nmcli, rc=2), and the PSK never transits nmcli argv (litclock-dev#599): connect uses --ask + stdin, restore uses connection edit with the secret fed on stdin. The version on public master today never fires.
  • litclock-dev#609: snapshot-and-diff profile cleanup, so a failed provisioning attempt leaves no armed NM profile with a wrong PSK.
  • litclock-dev#610: retry surfaces reflect the actual failure class (WifiFailure carries failure_class; e-ink retry variants; conditional banner advice).
  • litclock-dev#619: the page-build scan path is serialized under _SCAN_CACHE_LOCK.
  • litclock-dev#625 + #629: setup splash validates and clamps credentials (fixes the silent 10px font fallback); hotspot --ssid/--password validated where the AP is created; the /etc/issue box is sized at runtime and tested for alignment across the full admitted credential range.
  • litclock-dev#606: wifi hygiene (redacted sentinel argv, post-validation SSID storage, honest litclock-update.timer comment).
  • The litclock-dev#614 review-polish hunks that land in these files.

Port method and verification

Per-file public..dev delta against a per-file merge base, never wholesale copies of diverged files (the repos diverge bidirectionally). Every ported file was verified equivalent to litclock-dev master after normalizing the litclock-dev#NNN ref requalification; an independent review pass additionally confirmed wifi_provision.py and eink_display.py are AST-identical to dev, and traced every PSK path (stdin only, argv redacted on both result shapes, no temp secret files exist).

Public-only content preserved and pinned by tests: the #529 Setup-Incomplete poweroff branch in first-boot.sh (dev's "Or SSH in" copy stays replaced by "Unplug, then plug back in") plus its TestSetupIncompletePoweroff class, alongside dev's new TestIssueBoxAlignment.

Gates on this branch's tree: ruff clean; pytest 3,098 passed (freetype-gated renderer tests executed locally in a freetype venv, zero relevant skips); the ported wifi suite also ran green from a clean archive export (370 passed).

One deliberate divergence from dev found in review and kept: a test fixture UUID token that carried a real-world SSID name was renamed to a neutral token.

Fleet impact

None until a release is tagged: OTA is tag-gated, so merging to master exposes nobody. This train is the substance of the planned v0.224.0. Fresh-flash QA on the bench Pi matters more than usual for that release because the WiFi stack changed shape under litclock-dev#630, and fresh-flash is exactly what exercises it.

…ck-dev

File-level port of the wifi/provisioning seam of the litclock-dev #606-#631
train (dev PRs #606, #609, #610, #616, #619, #625, #629, #630, plus the
#614 review-polish hunks that land in these files):

- litclock-dev#606: redacted sentinel argv, post-validation SSID storage,
  honest litclock-update.timer comment
- litclock-dev#609: snapshot-and-diff profile cleanup - failed attempts
  leave no armed NM profile
- litclock-dev#610: retry surfaces reflect the actual failure class
  (WifiFailure carries failure_class; e-ink retry variants)
- litclock-dev#616 + #630: a reused profile's PSK survives a failed
  connect - #630 passwd-file connect + editor-stdin restore is the
  working form (the #616 snapshot listing is rejected by real nmcli),
  and the PSK no longer transits nmcli argv (litclock-dev#599)
- litclock-dev#619: page-build scan path serialized under _SCAN_CACHE_LOCK
- litclock-dev#625: setup splash validates + clamps credentials, fixes the
  silent 10px font fallback
- litclock-dev#629: hotspot --ssid/--password validated where the AP is
  created; /etc/issue box sized at runtime
- litclock-dev#614 (partial): review-polish items in setup_server and the
  wifi test files

Each file byte-verified against litclock-dev master modulo ref
requalification; public-only content (the #529 Setup-Incomplete poweroff
branch and its tests) preserved.
@kapoorankush
kapoorankush merged commit ae91f69 into master Aug 12, 2026
5 checks passed
@kapoorankush
kapoorankush deleted the feat/port-wifi-provisioning-train branch August 12, 2026 04:13
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