fix(install): make Stream (beta) correct on FW 11+ and actually verify it#185
Merged
Conversation
…y it Follow-up to the stream-install crash fix (#184), from the FW assessment. Two gaps that made "stream install is great" false, especially on FW 12: 1. FW-11 guard (client). The Stream path installs via the standalone DPI daemon, which has no kernel R/W and so can't acquire the SYSTEM install authid that FW 11+ requires for the content-copy — on FW 11+ it registers the title but lands NO content ("hollow" tile). The in-process installer (normal Upload→Install) DOES escalate correctly. So before a stream install on a console we KNOW is FW 11+, warn and point the user at the normal path (they can still proceed). Below FW 11 / unknown FW is unaffected. New `firmwareMajor()` helper (+3 tests) off the existing kernel-string parser. 2. Verify actually verifies (engine). install_status_handler returned CONFLICT for a session with no BGFT task_id — which is EVERY stream (serve_only) session — so the client's verifyInstallCompleted fell through to its optimistic "can't verify → assume done" branch and reported success without checking. A stream session has no task_id (the DPI daemon did the install in its own process), but completion is verifiable the SAME way the normal path verifies a Done: the on-disk launch-check (verify_launchable → is /user/app/<id>/app.pkg present) + byte observation, both filesystem-based and task_id-free. Synthesize a Done phase for the no-task_id case so the existing adaptive tracker runs (Registered ⇒ complete, Absent ⇒ still installing, flatline ⇒ stall). This also catches a hollow tile if a FW-11+ user proceeds past the guard. Engine build+fmt+clippy+80 tests, desktop clippy, client typecheck+lint+782 tests (+3), i18n 18 langs — all green. Still pending HW verification on the Pro (FW 9.60) once its payload is reloaded. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Follow-up to the stream-install crash fix (#184). The FW assessment turned up two gaps that made "stream install is great" false — especially on FW 12. Both fixed here.
1. FW-11+ guard (client)
The Stream path installs via the standalone DPI daemon, which has no kernel R/W and so can't acquire the SYSTEM install authid FW 11+ requires for the content-copy. On FW 11+ it registers the title but lands no content — a "hollow" tile that won't launch. The in-process installer (normal Upload → Install) does escalate correctly.
So before a stream install on a console we know is FW 11+, the client now warns and points the user at the normal path (they can still proceed). Below FW 11 / unknown FW is unaffected. New
firmwareMajor()helper (+3 tests) built on the existing kernel-string parser.2. Verify actually verifies (engine)
install_status_handlerreturned CONFLICT for any session with no BGFTtask_id— which is every stream (serve_only) session — so the client'sverifyInstallCompletedfell through to its optimistic "can't verify → assume done" branch and reported success without checking.A stream session has no
task_id(the DPI daemon installed in its own process), but completion is verifiable the same way the normal path verifies a Done: the on-disk launch-check (verify_launchable→ is/user/app/<id>/app.pkgpresent?) plus byte observation — both filesystem-based andtask_id-free. Synthesize aDonephase for the no-task_idcase so the existing adaptive tracker runs (Registered⇒ complete,Absent⇒ still installing, flatline ⇒ stall). This also catches a hollow tile if a FW-11+ user proceeds past the guard.Testing
Engine build + fmt + clippy + 80 tests; desktop clippy; client typecheck + lint + 782 tests (+3); i18n 18 langs — all green.
Type of Change
🤖 Generated with Claude Code