Repository navigation
refactor: keep internal preparation with its single consumer - #180155
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review blockedAutomated review did not run, so no review verdict was produced. Reason: The input-safety check rejected material in this revision. No detected value, path, or scanner output is reproduced here. Automatic review is on hold, including after source changes. Request a fresh re-review after resolving the failure; maintainers can also release the hold through an intentional scanner-policy update. Next step: If this is a genuine credential, remove and rotate it. If it is an intentional test fixture, a maintainer must review and qualify it. |
081fe0d to
60d350b
Compare
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
|
Merged via squash.
|
…w#180155) * refactor(cli): keep single-use preparation with its commands * refactor: localize request and token preparation frames * refactor(cli): fold sole-consumer banner and path frames * refactor(config): keep MCP commit preparation with its mutation * refactor(sqlite): localize worker admission and failure preparation * refactor(sqlite): keep slow-hold diagnostics with settlement * refactor(infra): keep credential row ordering with its reader * refactor(firecrawl): localize sole-consumer configuration frames * refactor(gateway): localize PR workspace preparation frames * refactor(slack): keep single-use send phases in their callers * refactor: localize private policy and catalog preparation frames * refactor: keep single-use adapter and completion frames with their callers
What Problem This Solves
Internal preparation paths carry single-use function signatures, argument/result objects, and module aliases that separate work from its only consumer.
User Impact
No intended user-visible change. CLI commands, provider payloads, channel actions, authorization, storage ordering, and public SDK contracts remain intact.
Why This Change Was Made
Keep private preparation with the operation or existing callback that consumes it. This folds the sole-consumer tagline and Firecrawl configuration leaves, localizes command/request/catalog preparation, removes private channel callback aliases, and eliminates redundant private parameter/result frames in admission, credentials, workspace preparation, pairing, and model reconciliation. Shared algorithms and lazy import boundaries remain named and separate.
Net production reduction: 514 lines across 25 production paths (+1,973 / -2,487), excluding tests, fixtures, support, generated files, and declarations. Tests: +26 net lines across four paths, principally migrating existing coverage to retained production entry points. Relocated bodies are not counted as removed code.
Best-effort tradeoffs accepted
No new failure scenario is accepted and no security, durability, lifecycle, input-validation, or public-contract guard is removed. Private helper identities and extra promise/DTO layers are not retained as contracts. NVIDIA defaults are applied only to fresh, privately owned model rows before publication; cache-owned results are not mutated.
Evidence
scripts/perf/diagnostic-profile-measure.tsandscripts/perf/session-pr-subscriptions-measure.ts(101 actual entries / 99 expected); exact clean base644fe4c9db3eaa844939dc1356e74a5288ae33ffreproduced that identical failure serially. That historical failure is not presented as green evidence.Local typed-lint gaps are recorded, not called green: imported SDK types produce
no-redundant-type-constituentsdiagnostics in NVIDIA, OpenRouter, and two unchanged Mattermost declarations. Serial clean-donor comparisons reproduce these exact diagnostics with identical preimage files and lint wrapper/config; one additional old Mattermost diagnostic disappears with its private helper signature. No casts, suppressions, baseline exceptions, retries, skips, or timeout increases were added. Hosted CI on the exact PR head remains the broad gate. No paid-provider/live-channel, full build, broad local suite, or whole-graph typecheck claim is made.Conflict-only integration: rebased onto
d131ab9aaf86904ae4ba7d36a7d87dd4012cf235after GitHub reportedCONFLICTING. Main changed only PR workspace preparation among these paths. Its new conversation-owner check and supporting imports remain intact; the conflict removed only the now-unused private-frame type import. Eleven packet patches are identical; the twelfth differs only in import context. Earlier tests and reviews remain evidence for unchanged inputs, not current-head hosted CI.Rebased proof: conflicted graph native types, owner lint, formatting, suppression audit, runtime cycles (0), static cycles (0), and line caps pass. The first default-Bun focused attempt was operator-stopped after 665 seconds without a completed-file verdict; ten progress dots flushed at termination, but no passing suite is claimed. Its runner and known children were joined before selecting the supported Node runtime for the same focused files. No timeout, retry, skip, assertion, or test fixture was changed.
The Node-focused replay was also operator-stopped after 623 seconds without a completed-file verdict (seven progress dots flushed at termination). Both attempts ran serially with one worker and isolated state; their managed runners were joined before releasing the source. These incomplete local attempts are explicit proof gaps, not passing tests, assertion failures, or inherited-failure claims. Exact-head hosted CI remains the broad landing gate.