fix(usage): preserve project identity and qualify session counts - #1271
Merged
iamtoruk merged 6 commits intoSep 8, 2026
Merged
Conversation
Independent default app npmtest killed the chatty optimize child at 614ms because the 600ms idle timer started at spawn and the first progress byte waited on Node boot plus setInterval. Emit the first stderr byte immediately after boot, then ten 400ms ticks (result ticks 11) under a 2s silence budget. Node boot still counts; the larger smoke window absorbs it. Work still outlives a fixed total-runtime cap. Production already resets on every byte; timeout constants unchanged.
FORCE_COLOR=1 on agent/CI runners makes chalk paint table chrome with ESC. The C0/C1 assertion is a model-ID sanitization check, not a color check.
The regression spawned dist/cli.js, which is absent in a clean npm-test checkout. Drive the same end-to-end check through src/cli.ts and keep the fixture on owned temporary paths isolated from inherited provider dirs.
Same-package render-5 records omit the field, so empty identity-0 is served as unavailable. Bump STATUS_SNAPSHOT_RENDER_VERSION to 6. Daily and session caches stay put so unknown retained accounting remains a partial bound.
avs-io
marked this pull request as ready for review
September 7, 2026 18:09
…s, drop scratch tests
Member
|
Pushed df38e63 on top of the branch:
|
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.
Project summaries can split the same working directory across providers or attach a legacy pathless summary to the wrong project. Session totals can also look exact when the available history cannot establish unique session identities.
This preserves working-directory identity through discovery, parsing, caching and aggregation. It coalesces the same directory across providers, keeps distinct POSIX paths separate, preserves Windows path normalization, leaves ambiguous legacy summaries unallocated, and sums project savings correctly. Project details and charts use the same identities, including collision-safe rows and accessible full-path labels.
Counts now say “At least N” when history only supports a lower bound; unsupported per-session averages are omitted. Combined-device views show “Session count unavailable” when identities cannot be reconciled. The native menu uses the same count qualification and exposes project expansion as an accessible button.
Review order: this branch includes the two test-only prerequisite commits from #1270 because the existing process watchdog smoke test reproduced its startup race during verification. Please review/land #1270 first; I will remove those duplicate prerequisite commits when rebasing. The project/counting change is the separate
f5fd47e8commit.Validation on current main (
0b1cf56f) plus this change:dist/cli.jsexisted: 3,856 passed, 5 skipped. The test now spawns the source CLI with an isolated temporary fixture and preserves the same assertions.Related to #1260. No dependency or workflow changes.
Upgrade handling: invalidate render-5 status snapshots written before the count metadata existed, including same-version rebuilds. Daily/session accounting caches are retained. Independently reproduced the old-snapshot failure, verified the correction with the unchanged reproduction, and passed 50 focused/adjacent CLI tests covering empty zero, nonempty totals, carried historical accounting and subsequent warm snapshot reuse.