Repository navigation
refactor: deslop plugin core and smaller runtime leftovers - #168220
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs changes before merge. What this changesThis PR consolidates repeated plugin, ACP, meeting-audio, Talk, setup, and system-agent logic under existing owners. Example: A meeting restarts audio playback while an output write is pending.
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 1 item remains Keep this maintainer-authorized refactor open: the consolidation is useful, and review found no actionable introduced defect; recorded validation qualification remains unfinished. Priority: P3 Before merge
FindingsNone. Tests
Agent review detailsHow this fits togetherCLI, setup, Gateway, and meeting callers enter core orchestration, which selects plugins, validates authority, persists state, and dispatches runtime or audio operations. flowchart TD
A[CLI and setup] --> C[Core orchestration]
B[Gateway and meetings] --> C
C --> D[Plugin metadata and lifecycle]
C --> E[ACP and system agent]
D --> F[Provider execution]
E --> G[State and audio operations]
Technical reviewBest possible solution: Retain the consolidation and finish its already-recorded validation before landing through the repository workflow. Do we have a high-confidence way to reproduce the issue? This is an internal refactor rather than a reported product defect; no target code or tests were executed during this read-only review. Is this the best way to solve the issue? The extractions reuse existing owners and preserve the examined policy, persistence, callback, cancellation, and audio-settlement contracts. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 2b787637a639. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
PR surfaceSource -789, Tests +4. Total -785 across 75 files. Added test files: 0. View PR surface stats
Review metrics
LabelsLabel changes: No label changes. Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (12 earlier review cycles; latest 8 shown)
Reviewed October 10, 2026, 1:50 PM ET / 17:50 UTC (Revision 13). |
18d29df to
e30fac9
Compare
e30fac9 to
d28ddd6
Compare
Combine the plugin core and smaller runtime cleanup lanes while preserving public contracts and owner-boundary behavior. Net production reduction: 824 lines. Canonical review finding about explicit non-wizard auth methods was rejected against the exact source and a passing direct runtime counterexample.
Keep the synthetic npm registry fixture limited to its declared providers by clearing known provider credential names through the existing state-fixture environment owner. Preserve all fault injections, assertions, and timeouts. The original case reproduced an unrelated provider repair; all 12 cases now pass with synthetic ambient-key presence.
d28ddd6 to
b902c4d
Compare
|
Inherited-CI exception for reviewed head The exact-head workflow 38063317129, attempt 2, completed. Final pre-submission exhaustive exact-head census: 207 checks — 125 successful, 79 skipped, one neutral, two failed, no pending or cancelled checks. Every failed job is attributed below; the ten cancelled siblings from attempt 1 were rerun rather than waived.
CI tested merge Six sequential isolated Linux runs, B,H,H,B,B,H, reproduced exactly 3 passed / 3 failed in every run on the exact CI base and merge. Median command wall time was 13.850274s base versus 14.013764s merge (+1.1804%); test time was 4.590085s versus 4.669077s (+1.7209%). Blacksmith comparison run, Node 24.19.0 / pnpm 12.9.0, independent dependency trees. An earlier loaded-Mac comparison exceeded timing parity and is retained as nonqualifying evidence, not hidden. Runtime/static qualification is now complete: all eight unit groups and both E2E groups have equal all-passing results and qualifying whole-command median times; all three sequential Knip configurations and both retained budget findings have identical diagnostics and qualifying timing. The graph budget required a larger predeclared 42-sample local comparison after its initial sub-second remote timing was nonqualifying; both experiments remain recorded in the PR. Canonical QA runtime/declaration builds passed for base and head. The public SDK comparison shows no API change. No test, timeout, retry, skip, budget, ignore, or suppression was weakened. Main now contains the independent fixture correction Independent hosted reproduction: #168337, job 114218785764, head Dependency-review and security-sensitive-review pass. The exact-head independent code review had no findings; the outstanding proof-completion item is now addressed. This documents the authorized pinned squash exception, not a green CI claim. Verified outcome: merged as |
…168220) * refactor: deslop plugin core and smaller runtime leftovers Combine the plugin core and smaller runtime cleanup lanes while preserving public contracts and owner-boundary behavior. Net production reduction: 824 lines. Canonical review finding about explicit non-wizard auth methods was rejected against the exact source and a passing direct runtime counterexample. * test(plugins): isolate post-core provider credentials Keep the synthetic npm registry fixture limited to its declared providers by clearing known provider credential names through the existing state-fixture environment owner. Preserve all fault injections, assertions, and timeouts. The original case reproduced an unrelated provider repair; all 12 cases now pass with synthetic ambient-key presence.
What Problem This Solves
Repeated internal paths make plugin core and smaller runtime behavior harder to maintain consistently.
User Impact
No intended user-visible change or required action. This is internal cleanup; no public SDK API, feature, dependency, config, schema, or protocol change.
Why This Change Was Made
Consolidates repeated logic under its existing owners: plugin manifest validation, provider selection, CLI callback binding and lifecycle; ACP controls and metadata; meeting process/audio handling; talk sampling and dispatch; setup flows and system-agent rendering.
Applies d42 (
4b925c4ea9a) then d44 (7acc96548a8). The current candidate isb902c4db3f1c90b11334cb42b19914c0b895b38d, based on main7b125134f3860743c55696b3f273ed82abe535dc. Three integration rounds retained main's newer behavior. Only two original production hunks were dropped:src/plugins/update-channel.ts: 22 net lines, superseded by main's bundled-path admission (76aabd1052a, fix: stop bundled plugin config churn during updates #168226).src/plugins/runtime/runtime-agent.ts: 13 net lines, superseded by main's extracted session creation and admission (6af860cacd8, refactor: prepare plugin and Codex incognito session consumers #168398).All remaining original production added/deleted lines were independently compared and retained unchanged. Temporary fixture fixes already supplied by main were dropped. One retained fixture correction uses the canonical environment scrubber so ambient provider credentials cannot inject an unrelated repair into synthetic dependency-health tests. Assertions, real npm calls, fault injection, deadlines and retries are unchanged.
Coverage log — 500–999-line bundle exception
789 net production lines removed: 71 production files, +1,396 / −2,185. Tests/support: four files, +15 / −11. All files: 75, net −785. The coordinator explicitly authorized this combined 500–999-line exception; d42 retains 302 net production lines removed and d44 retains 487.
Independent review inspected the complete changed production surface. The latest isolated P2 review had one rejected finding: removing an ignored
activeSessionKeyoption does not remove active-row protection. The canonical SQLite patch owner always supplies its resolved session key to maintenance, and the removed option is not part of the patch-options contract. The earlier explicit-auth-method finding was also rejected against source and a runtime counterexample. No accepted actionable finding remains.Evidence
Current-head proof:
ff7b090f.check-changedretained a global environment-budget failure: 456 names against 455. Clean base reproduces the same failure; the checker and budget sources are unchanged. The canonical continuation completed 35 subsequent checks with only that budget and the UI-root-count failure below; all other 33 passed. Two initial passed checks were reused, and only the explicitly requested sequential Knip scans were separated. No aggregate-green claim is made.POST_ACTIVATION_INSPECTIONS_STEP; full addsresolveSessionConversationStubandresolveSessionTargetStub; scripts finds the Solid plugin's default export. All finding owners are untouched and identical base/head. The Solid default is consumed by.oxlintrc.jsonjsPlugins. Every scan produced identical diagnostics; median whole-command wall times: production 46.046s base / 45.994s head (-0.11%), full 58.853s / 57.533s (-2.24%), scripts 28.178s / 28.202s (+0.085%). These remain inherited findings, not passing Knip claims.Broad coverage retained from the pre-integration candidate
c38057d08b2b:node scripts/run-vitest.mjs src/plugins src/acp src/meeting-bot src/talk src/flows src/wizard src/system-agent: 912 files (901 passed / eight failed / three skipped), 10,871 cases (10,834 passed / 23 failed / 14 skipped), 31,703.57s. Existing Windows/Bun/NOCOW skips were not added by this PR. Two opt-in live files were not run; no live claim is made.114184629910also passed 12/12 (89.398s summed case time; containing 15-file/157-case subgroup 269.56s Vitest / 273.57s wrapper). This is prior-head evidence, not current-head CI.3cfab51ef9a) and plugin-status fix (e7eece5bae3, test(plugins): status test fails since metadata snapshots carry diagnostics #168264). Sequential clean-base/candidate qualification follows below. Passing replays are not presented as fixes.The eight unit-failure groups are now fully qualified on isolated Blacksmith hosts against pinned clean base
7b125134f386and candidateb902c4db3f1c. Each group ran sequentially B,H,H,B,B,H with physically independent dependencies, isolated private HOME/TMP, and all 48 raw JSON reports verified. Every sample passed; the original broad failures remain recorded above, not claimed fixed by replay. Whole-command wall time was the predeclared primary timing metric:All groups meet primary wall parity with equal outcomes. Secondary test-only medians increased 6.27% (+197ms) for session color and 31.50% (+10.7ms) for plugin status; these are disclosed rather than substituted for the predeclared metric. Doctor capture and memory owners respectively had four and seven deliberately unselected cases. Corrected unit comparison lease. An earlier staging-permission failure and an incomplete download were discarded as unusable proof, not counted as passes.
Both remaining E2E comparisons completed on one isolated Blacksmith runner, with canonical private QA runtime/declaration builds and current-head artifact verification passing independently for base and head. All 12 measured runs passed, with all raw JSON reports verified:
The focused npm qualification intentionally left 14 other cases unselected; their prior full-file coverage is recorded above. Secondary test medians also met parity: ACP -1.84%, npm +0.81%. The combined remote command retained exit 1 because of inherited static findings and the original six-sample graph timing result; its E2E phase exited 0. The larger local graph follow-up qualified independently. One earlier lease expired while local source staging was still running and produced no Knip samples; the replacement used one lazy allocation and completed both phases. No expired or incomplete attempt is counted as passing proof.
Prior hosted run
38041670741, attempt two, is historical: 86 success, 24 skipped, three failed jobs plus the downstream gate, no cancellations remaining. Its memory-repro child-stdio and two UI failure owners are now fixed in the current base (e3415ea8c554,dd036a4b1d855/#168328,41c5bf805402) and unchanged by this diff. These old results do not excuse a new-head failure.Current-head CI run
38063317129, attempt one, had one failed test job:checks-node-changed-extensions-bundle-3-1(three Agents API steering-history expectations), plus its downstream gate and ten cancelled siblings. All failed/cancelled jobs were resubmitted. Attempt two is complete: 113 successful checks, 55 skipped, one neutral, the same test job and its downstream gate failed, and no cancellations remain. The full exact-head check inventory and both failure logs are retained.Six local runs on the exact CI base
23cf1bc3b6d2and tested merged0ddfdf0c898reproduced the same three assertions every time (targeted six-case group: three passed / three failed). The provider and transcript-owner sources are identical across those two revisions; changes of run, native binding or token budget invalidate the history cache but do not revoke the transcript admission. Cancellation and revocation remain enforced. Local wall-time medians differed by 22.42%, so that experiment did not qualify under the requested timing rule and remains recorded.The same B,H,H,B,B,H experiment on one isolated 16-vCPU Blacksmith Testbox reproduced the exact three failures in all six runs. Median command wall: 13.850s base / 14.014s merge (+1.18%); median test time: 4.590s / 4.669s (+1.72%). This qualifies the unrelated Agents API fixture failure as inherited; it does not turn the red CI job green. Testbox lease run, Node 24.19.0, pnpm 12.9.0, identical dependency inputs and physically independent checkouts. Cancelled jobs were treated as missing proof, never as main-red exceptions.
Final pre-submission exhaustive exact-head census: 207 check runs — 125 success, 79 skipped, one neutral, two failures, no pending or cancelled checks. The only failures are
checks-node-changed-extensions-bundle-3-1(114248060952) and its downstreamopenclaw/ci-gate(114251306827). Dependency-review and security-sensitive-review statuses pass; the combined status reflects the same CI failure. The latest independent review of this exact head had no code findings; its only completion item was the now-finished runtime/Knip qualification.During final refresh, main acquired the independent fixture correction
aec6e7a56eb03eaba1a648310876d2d6d4811745(#168569). The inspected conflict-free merge tree retains that correction, so this is an inherited failure of the recorded CI merge-ref, not a claim that current main still has the defect. No fourth integration or source change was made. All requested runtime and static qualification is complete. The explicitly authorized pinned inherited-CI exception merged this PR as21f5711b9c6607ab565d2d66b6a233780884e96d. After fetch, that squash commit was verified as an ancestor of origin/main, and its Agents API test matches the upstream correction exactly. The landed diff removes 789 net production lines. Evidence was posted before submission.The standing rule's unrelated-PR proof is #168337 job 114218785764, head
e25dd126256c1ca96dd144df71e9aa7e76bf1759: itschanged-extensions-config-29subshard reports 113 passed / the same three failed cases with the same expected-failed/received-ok signature. The failure path is not modified by this PR.