Skip to content

fix(tui): show the provisional ~ in the all-targets count scope - #352

Open
raphaelvigee wants to merge 1 commit into
masterfrom
fix/tui-all-scope-tilde
Open

fix(tui): show the provisional ~ in the all-targets count scope#352
raphaelvigee wants to merge 1 commit into
masterfrom
fix/tui-all-scope-tilde

Conversation

@raphaelvigee

Copy link
Copy Markdown
Member

The ~ on the header denominator means "this total is not final". The matched scope has always painted it while the matcher streams; the all scope never did — so pressing a toggled from 1 / ~800 done to 1 / 42 done, and that second number reads as a settled total it is not.

The all-scope total is if anything more provisional than the matched one: it grows both while the matcher streams and as running targets pull in deps that have not been observed yet. So it now carries the ~ while either can still happen, and drops it once the matcher has resolved and nothing is in flight.

A walk that never completed (failed or cancelled) never emits complete: true, so the ~ persists into the final summary — deliberately, and matching what the matched scope already does: the set never became final, so the denominator never became exact.

Tests

  • all_scope_total_carries_a_tilde_until_nothing_more_can_arrive — streaming → in-flight → settled.
  • all_scope_tilde_survives_a_walk_that_never_completed — both scopes keep the ~ after a failed walk.
  • all_scope_has_no_tilde_when_no_matched_event_ever_arrives — entry points that emit no Matched still settle to an exact total.
  • count_scope_toggles_done_and_cached_between_matched_and_all updated for the new all-scope rendering.

O(1) on the frame path, as before — two emptiness checks and two bools, no set walk.

🤖 Generated with Claude Code

https://claude.ai/code/session_019HV8Busq74eWVpUWVC5D69

The `~` on the header denominator means "this total is not final". The
matched scope has always painted it while the matcher streams; the all
scope never did, so `a` toggled from `1 / ~800 done` to `1 / 42 done` and
the second number reads as a settled total it is not.

The all-scope total is if anything *more* provisional than the matched
one: it grows both while the matcher streams and as running targets pull
in deps that have not been observed yet. So it carries the `~` while
either can still happen, and drops it once the matcher has resolved and
nothing is in flight.

A walk that never completed (failed or cancelled) never emits
`complete: true`, so the `~` persists into the final summary — matching
what the matched scope already does. The set never became final, so the
denominator never became exact.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019HV8Busq74eWVpUWVC5D69
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