Skip to content

fix(firmware): distinguish write rejection from session wedge - #113

Closed
millsmillsymills wants to merge 1 commit into
phase1from
fix/109-write-rejection-message
Closed

fix(firmware): distinguish write rejection from session wedge#113
millsmillsymills wants to merge 1 commit into
phase1from
fix/109-write-rejection-message

Conversation

@millsmillsymills

@millsmillsymills millsmillsymills commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

Follow-up from review of #105.

In _push_file, a storage_write that returns False on every attempt never lands the data, yet the function exited via the generic wedge message ("device RPC session stopped responding ... a transport reconnect clears the wedge"). For a pure write rejection that guidance is wrong — the data never reached the device, so reconnecting will not help.

Track whether any write succeeded (ever_written) and, when none did, raise a write-specific error pointing at free space / mount state. The corrupt-transfer (mismatch) and wedge (unreadable) paths are unchanged. Flash still fails closed before reboot in every case.

Added test_push_file_reports_write_rejection_distinctly_from_wedge; full installer suite 21 passed, ty + ruff clean.

Closes #109

🤖 Generated with Claude Code

A storage_write that is rejected on every attempt never lands the data,
yet _push_file exited via the generic wedge message advising a reconnect
to clear it - wrong guidance, since the data never transferred. Track
whether any write succeeded and raise a write-specific error when none
did, pointing at free space / mount state instead of a reconnect.

Closes #109

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@millsmillsymills

Copy link
Copy Markdown
Contributor Author

Superseded by the rebased copy (same commit, rebased onto current phase1); see newer PR.

@millsmillsymills
millsmillsymills deleted the fix/109-write-rejection-message branch June 10, 2026 08:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

Installer: wedge-recovery hint misleads on pure write-failure path

1 participant