Repository navigation
Fix empty modal cards on the TV's cached frame path - #169
Merged
Merged
Conversation
A settled embedded alert captures its panel ground before drawing its title, body and buttons. Mark that capture as already drawn in this frame so a later host::live scope cannot replay the foreground-free snapshot over those controls. All shared host-cache consumers inherit the fix without screen-specific changes. The host cache (becb4e5) predates #161. The sign-in cards are embedded alerts drawn before the dispatcher's modal-scrim scope, which is the order that trips it; whether older embedded alerts share that order was not checked. A cache-off simulator never enters this path, which is why #161's simulator captures looked complete while the television drew empty glass. Dispatcher page damage can repeat the capture after input. Regression first: the unmodified production host state machine failed with left [page, scrim, glass], right [page, scrim, glass, title/body/buttons] on the first settled frame. GL framebuffer copies are replaced by a CPU framebuffer; the host protocol and the freeze gate are the real ones. Cache-off and draw-last controls pass. The popover tests pass (12/12). This change has not yet been run on the television. Document the cache-promotion invariant and the simulator coverage limitation. Co-Authored-By: Claude Sonnet 5 <[email protected]>
The simulator runs with the frame cache off, so popover::host's cached stages never run there and a simulator capture cannot show a fault in them. Say so where the simulator's coverage is listed (ui-sim, which-tier Tier 1.5, agent-reference), since #161's captures read as complete while the television drew empty glass. Co-Authored-By: Claude Sonnet 5 <[email protected]>
`submit` and `queue_standing` appended a record and only then registered its delivery watch, so the ordinary flush (or compaction) could settle the record in the gap and the watch would come up Queued for a report that was already Delivered, or resurrect one `forget` had erased. `spool::append_watched_if` admits the watch under the spool lock, before the write, so neither the flush nor compaction can settle an unwatched record; a write failure fails the watch and a refused admission (permission, stale tenure, no capacity) permits no fallback. Both callers use it. Lock order stays spool then delivery. Regressions ran red first: the flush reducer, run at the point the lock is released and the submitter has not resumed, found Queued where Delivered was expected, for both entry points. Erasure winning, a stale worker, and compaction discarding the new record are covered too. Co-Authored-By: Claude Sonnet 5 <[email protected]>
The Details card took its body and answers once, at open. A receipt arriving while it was up left the support-only body on screen, and a failed delivery never gave *Send report* back to a card that had dropped it. `DecisionAlert::reconcile_card` compares the title, paragraphs and answers the card actually renders (not the incident's ID or state tag, which a receipt can leave unchanged) and updates in place: no restart of the entrance, valid focus kept, a removed answer hands focus to *Close*, and a newly available *Send report* does not steal it. A change drops the cached panel ground, since the body sizes the panel; unchanged content stays quiet. Login feeds it every tick while Details is open. Regressions ran red first: a receipt arriving while open, and a failed delivery that should offer Send again. Focus on removal of Send is covered, and the cached-ground invalidation is graded against the host state machine. Co-Authored-By: Claude Sonnet 5 <[email protected]>
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.
What
The two modal cards #161 added (the sign-in offer alert and the Details card) drew as empty glass on the television while the simulator drew them fully. Nothing in #161's checks could have seen it: the simulator runs with the frame cache off (
frame cache: CopyTexSubImage error=0x500 — cache off), so the cached host path was never exercised.Cause
popover::hostpromotes a captured page snapshot to a ground snapshot (stage two). The promotion did not mark the ground as already drawn this frame, so a laterhost::live()scope — the dispatcher's empty modal-scrim scope after Login's embedded alert — replayed the foreground-free ground over the alert's title, body and buttons. Input and the 2 s keepalive make unscoped page damage, which recaptures and re-trips it.Changes
ea960825The fix. A successful capture setsGROUND_DRAWN. Regression testui/popover_host_tests.rsdrives the real host state machine over a CPUFrameCachestand-in; it fails on the old code ([page, scrim, glass]where[..., title/body/buttons]is expected) and passes now.2cba7b34Docs. The simulator cannot see the cached modal ground; said so inui-sim,which-tierandagent-reference.6dfcafcbDelivery-watch race.submitandqueue_standingregistered the delivery watch after the spool append, so the ordinary flush (or compaction) could settle a record in the gap.spool::append_watched_ifregisters the watch under the spool lock, before the write; both callers use it. Lock order stays spool then delivery.860d2575Stale Details card. The card took its body and answers once at open, so a receipt arriving while it was up left the old body, and a failed delivery never gave Send report back.DecisionAlert::reconcile_cardcompares what the card renders, updates in place (no entrance restart, valid focus kept, a removed answer hands focus to Close), and drops the cached ground only when content changed.The last two were found in review of #161 and were written test-first, red then green.
Verification
make checkgreen on the pre-rebase tip; after rebasing onto Crash reporting: keep capture armed through a panic, retry unreadable envelopes, read nothing without a DSN #168 (no file overlap)make lintandcargo +nightly check --lib --no-default-featuresare green, full suite is CI's.🤖 Generated with Claude Code