Bugbot is paused β on-demand spend limit reached
Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.
A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.
Orchestration modules had 11 unclassified runtime exports. This keeps the ThreadSettlementReactor service constructor public, narrows seven implementation values, and deletes three unused error adapters without changing command, event, or projection contracts.
This is layer 2 of 9 in the server Knip cleanup stack.
The reactor constructor added on main uses the same explicit @public annotation.
Verification after rebasing onto current main: server typecheck and the server-only Knip export audit pass. Changed-file lint and formatting pass, with one existing lint warning. Focused auth, provider, source-control, preview toolkit, orchestration, and Knip preprocessor tests pass: 90 tests across 9 files. This changes server export visibility and static analysis; screenshots do not apply.
Model: gpt-6 astra. Harness: Codex in T3 Code.
Refactor
Documentation
Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.
A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.
β Thread transfer remains within every enforced ceiling.
βΉοΈ No successful
mainbaseline artifact is available yet. This run establishes the initial measurement.
| Provider | Metric | Main baseline | This PR | Impact | PR ceiling | |
|---|---|---|---|---|---|---|
| Codex | Total thread wire | β | 13.6 KiB | β | 15.1 KiB | β |
| Codex | Thread snapshot wire | β | 7.0 KiB | β | 7.3 KiB | β |
| Codex | Live turn WebSocket wire | β | 6.6 KiB | β | 7.8 KiB | β |
| Codex | Live turn WebSocket decoded | β | 57.1 KiB | β | 66.4 KiB | β |
| Codex | Live turn messages | β | 10 | β | 21 | β |
| Claude | Total thread wire | β | 13.5 KiB | β | 15.1 KiB | β |
| Claude | Thread snapshot wire | β | 7.1 KiB | β | 7.3 KiB | β |
| Claude | Live turn WebSocket wire | β | 6.5 KiB | β | 7.8 KiB | β |
| Claude | Live turn WebSocket decoded | β | 57.8 KiB | β | 66.4 KiB | β |
| Claude | Live turn messages | β | 8 | β | 21 | β |
Baseline: unavailable Β· PR result: 1c4dfee Β· Source CI: success
10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.
Verdict: Approved at 1c4dfee
Macroscope's review found this PR approvable β This PR tightens internal orchestration exports and adds API classification comments without changing runtime logic, configuration values, schemas, or service wiring. Repository usage confirms the removed symbols are not consumed in-tree; only unsupported deep imports of internal modules could be affected.
You can add or adjust custom eligibility rules. Learn more.
Added 2 commits
Review Change StackReview Change Stack
No actionable comments were generated in the recent review. π
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Advanced
Run ID: e0bb0f5d-a570-44bd-bbe1-920bc98e244a
Reviewing files that changed from the base of the PR and between 52679c3a00274b06fd2cc2a4e678bfe1455cd870 and 1c4dfeec34410f080a13c3201fd45494fea2350b.
apps/server/src/orchestration/Errors.tsapps/server/src/orchestration/LiveStreamBudget.tsapps/server/src/orchestration/ThreadPullRequestReactor.tsapps/server/src/orchestration/ThreadSettlementPolicy.tsapps/server/src/orchestration/ThreadSettlementReactor.tsapps/server/src/orchestration/commandInvariants.tsapps/server/src/orchestration/runtimeLayer.tsIncluded review availability: Your plan provides up to 10 included reviews per hour; 0 remain after this review.
The change narrows the orchestration module API by removing selected exports and error helpers. It also documents service construction APIs as public Effect module entry points without changing runtime behavior.
Orchestration API surface
| Layer / File(s) | Summary |
|---|---|
Restrict orchestration module exports apps/server/src/orchestration/Errors.ts, apps/server/src/orchestration/LiveStreamBudget.ts, apps/server/src/orchestration/ThreadSettlementPolicy.ts, apps/server/src/orchestration/commandInvariants.ts, apps/server/src/orchestration/runtimeLayer.ts | Selected error factories, budget constants, settlement constants, invariant helpers, and runtime layer constants are no longer exported. Their behavior and composition remain unchanged. |
Document canonical service construction apps/server/src/orchestration/ThreadPullRequestReactor.ts, apps/server/src/orchestration/ThreadSettlementReactor.ts | The make service construction APIs receive @public documentation annotations. Runtime code is unchanged. |
Estimated code review effort: 1 (Trivial) | ~5 minutes
Merge Risk: βͺ Minimal Β· up to 1c4df
This change narrows internal orchestration exports and documents service construction APIs without intended runtime or contract changes. No concrete current-head merge risk remains.
| Check name | Status | Explanation | Resolution |
|---|---|---|---|
| Docstring Coverage | β οΈ Warning | Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 6 files. | Write docstrings for the functions missing them to satisfy the coverage threshold. |
| Check name | Status | Explanation |
|---|---|---|
| Title check | β Passed | The title clearly identifies the server refactor and the classification of orchestration exports. |
| Description check | β Passed | The description explains what changed, why the change was made, scope, verification results, and that UI evidence does not apply. It does not use the template headings or checklist, but it contains thβ¦ |
| Linked Issues check | β Passed | Check skipped because no linked issues were found for this pull request. |
| Out of Scope Changes check | β Passed | Check skipped because no linked issues were found for this pull request. |
cleanup-server/orchestration-internalsComment @coderabbitai help to get the list of available commands.