Skip to content

test(onboard): remove redundant inference test bridge - #121574

Merged
steipete merged 1 commit into
mainfrom
claude/remove-onboard-inference-test-bridge
Aug 10, 2026
Merged

steipete merged 1 commit into
mainfrom
claude/remove-onboard-inference-test-bridge

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

Removes a redundant private-detector test and the test-only global bridge it required.

Why This Change Was Made

The retained owner-boundary tests already cover Codex login status, all six macOS app paths, and inference precedence and ranking.

User Impact

None.

Evidence

  • 29 onboarding inference tests passed.
  • 127 setup inference tests passed.
  • Full changed gates for core and core tests passed, including lint, type checks, dead-code checks, and import-cycle checks.
  • Autoreview and secret scanning passed.

@clawsweeper

clawsweeper Bot commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@openclaw-barnacle openclaw-barnacle Bot added commands Command implementations size: XS maintainer Maintainer-authored PR labels Aug 10, 2026
@steipete steipete self-assigned this Aug 10, 2026
@steipete
steipete force-pushed the claude/remove-onboard-inference-test-bridge branch from c7cef8c to f57aa6e Compare August 10, 2026 11:41
@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 10, 2026
@clawsweeper

clawsweeper Bot commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 10, 2026, 7:44 AM ET / 11:44 UTC.

ClawSweeper review

What this changes

The branch deletes a redundant direct Codex-app discovery test, its test-support bridge, and the production test-mode global used only by that bridge.

Merge readiness

⚠️ Ready for maintainer review - 1 item remains

Keep open. This active maintainer cleanup removes a test-only global exposure whose only direct assertion is already covered through the public onboarding inference path.

Priority: P3
Reviewed head: f57aa6e43f59e0865fc81c84f2d16dd3a8e121b9

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused, net-negative cleanup with retained owner-boundary coverage and no correctness finding.
Proof confidence 🌊 off-meta tidepool Not applicable: The real-behavior gate is not applicable to this maintainer-authored cleanup; the PR body records focused test and changed-gate runs.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The real-behavior gate is not applicable to this maintainer-authored cleanup; the PR body records focused test and changed-gate runs.
Evidence reviewed 5 items Single production path: The private native-Codex helper is invoked by detectInferenceBackends, which supplies its result to the ranked candidate flow; removing only the test-mode global does not alter that path.
Remaining behavior coverage: The retained tests exercise login-status probing with the discovered macOS executable and table-drive all six system/user ChatGPT, Codex, and Codex Beta application paths through the exported detection API.
Patch scope: The proposed commit deletes 5 production test-hook lines and 36 test/test-support lines, with no added behavior or dependency changes.
Findings None None.
Security None None.

How this fits together

Onboarding combines existing configuration, environment credentials, and local CLI probes into ranked inference-backend candidates for guided setup. This change only removes a test-only shortcut into that detection flow.

flowchart LR
A[Configuration and environment] --> C[Onboarding inference detection]
B[Local CLI probes] --> C
C --> D[Ranked backend candidates]
D --> E[Guided setup]
F[Focused onboarding tests] --> C
Loading

Before merge

  • Complete next step (P2) - This active maintainer-authored PR has no discrete repair finding; it only needs routine exact-head CI and maintainer review.
Agent review details

Security

None.

PR surface

Source -28, Tests -13. Total -41 across 3 files.

View PR surface stats
Area Files Added Removed Net
Source 2 0 28 -28
Tests 1 0 13 -13
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 3 0 41 -41

Review metrics

Metric Value Why it matters
Production versus test LOC production -5, tests/test-support -36 The patch is net-negative and removes a test-only production hook while retaining the owner-boundary coverage.

Technical review

Best possible solution:

Retain the public-path login and macOS-app discovery coverage while deleting the private global bridge and its duplicate direct assertion.

Do we have a high-confidence way to reproduce the issue?

Not applicable — this cleanup does not report a user bug; source inspection shows the retained tests exercise the observable detection path.

Is this the best way to solve the issue?

Yes — the private helper has one production caller, while retained exported-API tests cover login probing and every macOS application path, making deletion of the bridge the leaner solution.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against c3f4d5ee601a.

Labels

Label changes:

  • add P3: This is a low-risk test-maintenance cleanup with no user-visible behavior change.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: The real-behavior gate is not applicable to this maintainer-authored cleanup; the PR body records focused test and changed-gate runs.

Label justifications:

  • P3: This is a low-risk test-maintenance cleanup with no user-visible behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: The real-behavior gate is not applicable to this maintainer-authored cleanup; the PR body records focused test and changed-gate runs.

Evidence

What I checked:

  • Single production path: The private native-Codex helper is invoked by detectInferenceBackends, which supplies its result to the ranked candidate flow; removing only the test-mode global does not alter that path. (src/commands/onboard-inference.ts:227, c3f4d5ee601a)
  • Remaining behavior coverage: The retained tests exercise login-status probing with the discovered macOS executable and table-drive all six system/user ChatGPT, Codex, and Codex Beta application paths through the exported detection API. (src/commands/onboard-inference.test.ts:430, c3f4d5ee601a)
  • Patch scope: The proposed commit deletes 5 production test-hook lines and 36 test/test-support lines, with no added behavior or dependency changes. (src/commands/onboard-inference.ts:172, f57aa6e43f59)
  • Feature provenance: Blame attributes the probe helper and test-only global to the recent onboarding refactor; its author is also the current-area contributor proposing the cleanup. (src/commands/onboard-inference.ts:172, bab4546b4189)
  • Dependency boundary: The changed code only removes an OpenClaw test seam around local command probing; it neither imports nor changes a Codex harness, runtime, or protocol contract, so sibling Codex-source inspection is not applicable. (src/commands/onboard-inference.ts:162, c3f4d5ee601a)

Likely related people:

  • steipete: Current-main blame attributes the native Codex probe and its test bridge to this contributor's recent refactor, and the proposed cleanup is on the same owned surface. (role: feature introducer and recent area contributor; confidence: high; commits: bab4546b4189, f57aa6e43f59; files: src/commands/onboard-inference.ts, src/commands/onboard-inference.test.ts)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Allow the exact-head CI run to complete before merge.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@steipete
steipete force-pushed the claude/remove-onboard-inference-test-bridge branch from f57aa6e to 9e4ce77 Compare August 10, 2026 13:28
@steipete

Copy link
Copy Markdown
Contributor Author

Land-ready at 9e4ce7736491e43e28b10cd66548b84f85188013.

Validation:

  • node scripts/run-vitest.mjs src/commands/onboard-inference.test.ts — 29 passed
  • setup-inference focused suite — 127 passed
  • full selected core/coreTests changed gate — passed before the original commit
  • mandatory autoreview and TruffleHog — clean, no actionable findings
  • Linux Node 24 prompt snapshot generation/check in a temporary Ubuntu VM — current, no branch diff
  • exact-head CI run 31393109066 — green
  • scripts/pr review-validate-artifacts 121574 — READY FOR /prepare-pr, zero findings
  • OPENCLAW_TESTBOX=1 scripts/pr prepare-run 121574 — hosted exact-head gates passed at 2026-08-10T13:42:35Z

ClawSweeper had no code findings; its only rank-up move was exact-head CI, now satisfied. No proof gaps remain for this behavior-neutral test cleanup.

@steipete
steipete merged commit 14f8ed1 into main Aug 10, 2026
122 checks passed
@steipete
steipete deleted the claude/remove-onboard-inference-test-bridge branch August 10, 2026 13:43
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

commands Command implementations maintainer Maintainer-authored PR P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant