Skip to content

refactor(plugins): reuse worker optional-method validation - #147925

Merged
vincentkoc merged 1 commit into
mainfrom
refactor/worker-provider-optional-method-validation-20260914
Sep 14, 2026
Merged

vincentkoc merged 1 commit into
mainfrom
refactor/worker-provider-optional-method-validation-20260914

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Sep 14, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

Worker-provider registration validates listMachineOptions in a separate block even though it has the same contract as the existing optional-method loop.

User Impact

Registration acceptance, validation order and error messages stay unchanged.

Why This Change Was Made

Append listMachineOptions at its existing position in the ordered optional-method checks and remove the duplicate block. Required methods and all later contract checks remain unchanged. Production: −9 lines; tests unchanged.

Evidence

  • Personal review covered the complete validator and public registration tests, registry registrar, provider ID normalizer, worker-provider type contract and the original optional machine-options change.
  • Existing tests cover malformed machine-options registration, other optional methods and normal registration. The move preserves the same property reads, first-error ordering and diagnostic bytes.
  • Signed head 5dc501702d868b0f475da5c79f153e43ba2a86a3 passed local whitespace checks and required P2 review with no actionable findings. The review used the supplied diff; primary review supplied full owner and contract context. The staged classifier selected normal lanes without executing them.
  • Ready CI attempt 1 passed 119 jobs with 17 unselected skips, including the required gate. The actual tested merge dc1437aae6045bc34300fd9ba230d933ed2e26b9 contains the exact reviewed source and unchanged tests. Production/test types, lint, pinned formatting, dependencies, boundaries and build passed.
  • Actual public registry execution passed all 22 cases without target skips. These cover machine-options and other optional methods, required methods, successful registration, placement, SSH identity, ownership, provider IDs, duplicates and durable-owner selection.
  • The latest full ClawSweeper review covers the exact head and has no findings or Before merge items. Stale local dependencies were not used for runtime proof. No worker allocation, lifecycle, SSH or provider API behavior changes or live provider execution is claimed.

@vincentkoc vincentkoc self-assigned this Sep 14, 2026
@clawsweeper

clawsweeper Bot commented Sep 14, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@vincentkoc
vincentkoc marked this pull request as ready for review September 14, 2026 05:07
@vincentkoc

Copy link
Copy Markdown
Member Author

@clawsweeper review

@clawsweeper

clawsweeper Bot commented Sep 14, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event exact_review_queue).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

Re-review progress:

@openclaw-barnacle openclaw-barnacle Bot added size: XS maintainer Maintainer-authored PR labels Sep 14, 2026
@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 Sep 14, 2026
@clawsweeper

clawsweeper Bot commented Sep 14, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 14, 2026, 3:10 AM ET / 07:10 UTC (Revision 2).

ClawSweeper review

What this changes

Consolidates cloud-worker provider optional-method checks into the existing validation loop while preserving registration results and diagnostics.

Merge readiness

✅ Ready for maintainer review

The refactor is behavior-preserving and has no actionable findings. It remains distinct from current main, and its MEMBER authorship and maintainer label preclude automatic closure.

Priority: P3
Reviewed head: 5dc501702d868b0f475da5c79f153e43ba2a86a3

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused, maintainable simplification with equivalent validation semantics and existing registration coverage.
Proof confidence 🌊 off-meta tidepool Not applicable: The MEMBER-authored PR is exempt from the external-contributor proof gate; its validator-only refactor changes no authority boundary, and the linked registration tests are supplemental evidence.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The MEMBER-authored PR is exempt from the external-contributor proof gate; its validator-only refactor changes no authority boundary, and the linked registration tests are supplemental evidence.
Evidence reviewed 7 items Introduced change preserves validation semantics: The pinned introduction delta moves listMachineOptions immediately after prepareProvision in the existing loop. Undefined handling, property reads, first-error ordering, and diagnostic text remain equivalent; all subsequent checks are unchanged.
Current main and release retain the separate check: Inspected the validator at fetched main and v2026.9.4; both retain the standalone listMachineOptions block. The proposed consolidation is not already present in either inspected revision.
Existing registration boundary and coverage: The registrar calls this validator before inserting a provider. Existing public registration tests cover malformed machine-options hooks, the other optional methods, required methods, successful registration, ownership, and duplicates. Tests were inspected, not executed during this read-only review.
Findings None None.
Security None None.

How this fits together

The plugin registry validates cloud-worker providers before making them available to the Gateway. Provider methods and manifest declarations enter this check; accepted registrations or diagnostic errors leave it.

flowchart TD
  A[Plugin provider registration] --> B[Required method checks]
  B --> C[Optional method checks]
  C --> D[Remaining contract and ownership checks]
  D --> E{Valid registration?}
  E -->|Yes| F[Worker provider registry]
  E -->|No| G[Registration diagnostic]
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Source -9. Total -9 across 1 file.

View PR surface stats
Area Files Added Removed Net
Source 1 1 10 -9
Tests 0 0 0 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 1 1 10 -9

Review metrics

None.

Technical review

Best possible solution:

Keep optional function validation in the existing ordered loop without changing the public provider contract.

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

Not applicable: this PR claims a behavior-preserving refactor, not a runtime defect; source comparison confirms equivalent checks.

Is this the best way to solve the issue?

Yes: extending the existing loop removes duplicate validation without introducing another helper, changing the API, or requiring new tests that mirror implementation structure.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 322e27210a48.

Labels

Label justifications:

  • P3: This is a small internal cleanup with no change to accepted registrations or user-visible behavior.
  • 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 MEMBER-authored PR is exempt from the external-contributor proof gate; its validator-only refactor changes no authority boundary, and the linked registration tests are supplemental evidence.

Evidence

What I checked:

  • Introduced change preserves validation semantics: The pinned introduction delta moves listMachineOptions immediately after prepareProvision in the existing loop. Undefined handling, property reads, first-error ordering, and diagnostic text remain equivalent; all subsequent checks are unchanged. (src/plugins/worker-provider-registry.ts:20, 5dc501702d86)
  • Current main and release retain the separate check: Inspected the validator at fetched main and v2026.9.4; both retain the standalone listMachineOptions block. The proposed consolidation is not already present in either inspected revision. (src/plugins/worker-provider-registry.ts:20, 322e27210a48)
  • Existing registration boundary and coverage: The registrar calls this validator before inserting a provider. Existing public registration tests cover malformed machine-options hooks, the other optional methods, required methods, successful registration, ownership, and duplicates. Tests were inspected, not executed during this read-only review. (src/plugins/worker-provider-registry.test.ts:88, 5dc501702d86)
  • Existing optional plugin contract: WorkerProvider already declares listMachineOptions as an optional asynchronous function. The patch changes neither this API nor provider execution, persistence, or authorization. (src/plugins/capability-provider.types.ts:271, 5dc501702d86)
  • Feature-history routing: Current-main file history repeatedly identifies Peter Steinberger in worker-provider changes, including machine selection. GitHub commit metadata maps that author to steipete and exposes the original machine-options validation patch. Local blame and pickaxe inspection encountered an unavailable historical object, so no source-line introduction pointer is asserted. (src/plugins/worker-provider-registry.ts, 78beccf05397)
  • Supplemental CI evidence: GitHub confirms the linked checks-node-compact-large-10 job succeeded for the pinned PR head. The captured PR body reports 22 passing registry cases; this is supplemental test evidence, not live cloud-provider execution. (5dc501702d86)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

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.

History

Review history (1 earlier review cycle)
  • reviewed 2026-09-14T05:19:10.418Z sha 5dc5017 :: needs maintainer review before merge. :: none

@vincentkoc
vincentkoc merged commit 0d081a0 into main Sep 14, 2026
262 checks passed
@vincentkoc
vincentkoc deleted the refactor/worker-provider-optional-method-validation-20260914 branch September 14, 2026 07:39
@vincentkoc

Copy link
Copy Markdown
Member Author

Merged via squash.

vincentkoc added a commit that referenced this pull request Sep 14, 2026
* commit '8e6fe8e02ddb51bfec4e80071f0f2adcae4cf098': (47 commits)
  refactor: simplify Gateway health response parsing (#147834)
  fix: avoid Gateway stalls when renaming sessions (#147869)
  refactor(plugins): reuse worker optional-method validation (#147925)
  refactor(infra): remove unreachable firewall diagnostic fallback (#147882)
  fix(ui): open attached automations from session hovercards (#147749)
  refactor(reply): share usage-bar numeric coercion (#147863)
  fix(doctor): report warnings for keyed agent configs (#123058)
  perf(plugins): reuse complete registry comparisons (#147893)
  fix(workboard): await lifecycle sweep completion in tests (#147950)
  fix: reduce stalls when browsing large session inventories (#147911)
  refactor(onboard): share custom model definition (#147915)
  feat(ios): collapse completed chat work above replies (#148002)
  fix(voice-call): retain state runtime for deferred streams (#147689)
  test(qa): compare Telegram entities semantically (#147752)
  fix(plugins): preserve runtime scope for deferred CLI actions (#147688)
  test(qa): keep Slack progress marker visible (#147748)
  test(qa): finish channel picker prompts (#147730)
  test(tui): handle auth restriction prompt (#147729)
  fix(qa): retain onboarding prompts across redraw bursts (#147687)
  fix(qa): seed Teams ambiguous timeout deterministically (#147686)
  ...
vincentkoc added a commit to SunnyShu0925/openclaw that referenced this pull request Sep 14, 2026
* commit '069710f909f0a7158777d0fc0bf1eab84e20c699': (45 commits)
  refactor(infra): consolidate update campaign reset ownership (openclaw#146555)
  refactor: simplify Gateway health response parsing (openclaw#147834)
  fix: avoid Gateway stalls when renaming sessions (openclaw#147869)
  refactor(plugins): reuse worker optional-method validation (openclaw#147925)
  refactor(infra): remove unreachable firewall diagnostic fallback (openclaw#147882)
  fix(ui): open attached automations from session hovercards (openclaw#147749)
  refactor(reply): share usage-bar numeric coercion (openclaw#147863)
  fix(doctor): report warnings for keyed agent configs (openclaw#123058)
  perf(plugins): reuse complete registry comparisons (openclaw#147893)
  fix(workboard): await lifecycle sweep completion in tests (openclaw#147950)
  fix: reduce stalls when browsing large session inventories (openclaw#147911)
  refactor(onboard): share custom model definition (openclaw#147915)
  feat(ios): collapse completed chat work above replies (openclaw#148002)
  fix(voice-call): retain state runtime for deferred streams (openclaw#147689)
  test(qa): compare Telegram entities semantically (openclaw#147752)
  fix(plugins): preserve runtime scope for deferred CLI actions (openclaw#147688)
  test(qa): keep Slack progress marker visible (openclaw#147748)
  test(qa): finish channel picker prompts (openclaw#147730)
  test(tui): handle auth restriction prompt (openclaw#147729)
  fix(qa): retain onboarding prompts across redraw bursts (openclaw#147687)
  ...
vincentkoc added a commit to nvtoroy/openclaw that referenced this pull request Sep 14, 2026
* commit '4ddb9ed21245eaca9f243e555a5ec070aaaf0dad': (113 commits)
  fix: avoid Gateway stalls when renaming sessions (openclaw#147869)
  refactor(plugins): reuse worker optional-method validation (openclaw#147925)
  refactor(infra): remove unreachable firewall diagnostic fallback (openclaw#147882)
  fix(ui): open attached automations from session hovercards (openclaw#147749)
  refactor(reply): share usage-bar numeric coercion (openclaw#147863)
  fix(doctor): report warnings for keyed agent configs (openclaw#123058)
  perf(plugins): reuse complete registry comparisons (openclaw#147893)
  fix(workboard): await lifecycle sweep completion in tests (openclaw#147950)
  fix: reduce stalls when browsing large session inventories (openclaw#147911)
  refactor(onboard): share custom model definition (openclaw#147915)
  feat(ios): collapse completed chat work above replies (openclaw#148002)
  fix(voice-call): retain state runtime for deferred streams (openclaw#147689)
  test(qa): compare Telegram entities semantically (openclaw#147752)
  fix(plugins): preserve runtime scope for deferred CLI actions (openclaw#147688)
  test(qa): keep Slack progress marker visible (openclaw#147748)
  test(qa): finish channel picker prompts (openclaw#147730)
  test(tui): handle auth restriction prompt (openclaw#147729)
  fix(qa): retain onboarding prompts across redraw bursts (openclaw#147687)
  fix(qa): seed Teams ambiguous timeout deterministically (openclaw#147686)
  refactor(mcp): load OAuth only when credentials are needed (openclaw#147884)
  ...
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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