Repository navigation
fix: preserve sparse fan-out roster rows - #518
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Team Run ID: ⛔ Files ignored due to path filters (8)
📒 Files selected for processing (5)
Included review availability: Your plan provides up to 8 included reviews per hour; 3 remain after this review. WalkthroughThe roster projection now indexes each materialized output item and projects only those indexes. This preserves nonzero and sparse fan-out indexes. Tests cover roster items, rollups, and progress totals. A frontend comment clarifies the ChangesFan-out roster projection
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to The PR corrects sparse fan-out roster and progress reporting and restores a pinned build dependency needed for clean code generation. The changes are covered by passing tests and validation, with no actionable merge-blocking risk remaining. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Linked Issues checkExplanation The changes address issue Full details: Out of Scope Changes checkExplanation The reviewed changes support the stated objectives. The roster fix, regression tests, and related comment update are relevant to sparse fan-out reporting. Excluded documentation files cannot be assessed, but they are not required to validate the coding objectives.
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
React Doctor found no new issues. 🎉 Reviewed by React Doctor for commit |
5264e2f to
5a31461
Compare
5a31461 to
d18a163
Compare
|
| Filename | Overview |
|---|---|
| internal/loop/roster_helpers.go | Replaces maximum-index tracking with sorted lists of exact persisted item indexes. |
| internal/loop/roster_projection.go | Projects fan-out rows only for persisted indexes, preventing synthetic pending rows in sparse ranges. |
| internal/loop/roster.go | Wires exact output-index projection into the roster read path without changing its public shape. |
| internal/loop/roster_test.go | Adds canonical coverage for lone and non-contiguous sparse fan-out workers, rollups, and progress. |
| packages/site/content/docs/loops/running.mdx | Documents that fan-out source indexes may be sparse and that absent indexes do not count as workers. |
| skills/compozy/references/loops.md | Aligns the official agent guidance with sparse roster semantics and durable not-taken evidence. |
| web/src/systems/loops/lib/loop-run-fanout-band.ts | Corrects the comment describing not-taken segments without changing runtime behavior. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart LR
A[Persisted generation outputs] --> B[Group exact item indexes by generation and node]
B --> C[Sort sparse indexes]
C --> D[Project one roster row per persisted index]
D --> E[Compute progress and fan-out rollups]
C -. Missing indexes are not projected .-> D
Reviews (1): Last reviewed commit: "test: verify sparse fan-out roster repor..." | Re-trigger Greptile
|
@CodeRabbit full review |
✅ Action performedFull review finished. |
What & why
Fixes #506.
Fan-out roster projection treated the highest persisted item index as a contiguous range. When only item
2, or items2and5, existed, CompozyOS invented rows for the missing indexes and left them pending. This change projects only the exact persisted item indexes, so roster rows, rollups, and run progress describe the workers that actually exist.The change also documents sparse-index behavior in the Loop running guide and the official Compozy skill, and corrects the stale Web source comment about
not_taken.After rebasing onto the current
main, exact-head CI exposed a base regression:scripts/sync-emojibase.mjsresolves its data throughweb/package.json, but the required Web development dependency had been removed. This PR restores the pinned dependency so clean installs can execute the repository's codegen contract.How you verified it
make gatepassed on the rebased diff with fresh Go lint, Go race-test, and all-workspace JS records.go test -race -cover ./internal/loop -count=1passed all 1,086 tests. Changed functions have 89.2%-100% coverage.internal/loop.TestRosterContractregression first reproduced the bug ([0 1 2 3 4 5]instead of[2 5]) and now passes for both lone and non-contiguous sparse indexes.compozy__loop_runs, and the headed Web UI. The observed worker indexes were exactly2and2,4; rollup was2/2; run-list progress was3/3; Web refresh preserved the result.clean: trueand no surviving processes.mainreproduced the Emojibase resolution error. A fresh clone of this branch passedbun install --frozen-lockfilefollowed bymake codegen-check.OpenAI Codex co-wrote this change. I reviewed the diff and verified the result locally.
Impact
not_takensource comment was updated, and the pinned codegen data dependency was restored.packages/site/content/docs/loops/running.mdxandskills/compozy/references/loops.md.config.tomlkey, default, or lifecycle changed.compozy__loop_runsinherits the corrected shared roster projection.workspace_idpropagation changed. Loop outputs remain workspace-scoped through CLI, HTTP, UDS, core, store, Web, events, and cache reads.not_takenrequires durable route evidence.make gatepasses locally; this PR is delivered only after its required CI checks are greenSummary by CodeRabbit
Bug Fixes
Documentation