Skip to content

fix(ci): drain plugin publication Git before trust and readback - #133368

Merged
steipete merged 5 commits into
mainfrom
steipete/git-owner-plugin-release
Aug 30, 2026
Merged

steipete merged 5 commits into
mainfrom
steipete/git-owner-plugin-release

Conversation

@steipete

@steipete steipete commented Aug 30, 2026 •

Copy link
Copy Markdown
Contributor

Related: Git lifecycle ownership campaign.

What Problem This Solves

Fixes an issue where plugin ClawHub or npm publication could select a trust fallback, publish a target SHA, hash source metadata, or invoke publication consumers after GNU timeout observed only the Git leader while child or grandchild writers were still alive.

The affected workflows also flattened Git inspection failures into product decisions: main ancestry errors could look like “try release/*,” release-ref enumeration failure could look like no release branches, and incomplete git show output could be redirected into a source package.json file before hashing and immutable evidence verification.

Why This Change Was Made

Plugin ClawHub Release and Plugin NPM Release now prepare the reviewed canonical owner at dd4528b6393e7d00063067a080ca7241b48ce475 before selected-source or trusted-tooling checkout.

Trusted inline policies own ClawHub target resolution, protected-tag validation, and main/release/alpha trust; npm target resolution, preflight/extended-stable identity, and main/release/alpha trust; and both exact source-package readbacks. In ancestry admission, only documented merge-base status 1 advances to another trust source; other ancestry errors and release-ref enumeration failures are terminal. ClawHub deliberately preserves local-to-origin ref fallback after safely drained ordinary probe failures, as the original shell if/elif did. Resolving that candidate does not authorize publication: independent workflow-SHA/protected-tag binding and trusted ancestry still apply. Owner setup/inspection/cleanup failure and cancellation are terminal throughout, including at the resolver fallback boundary.

The migration preserves existing transport contracts: ClawHub retains three possible 120-second fetch sites; npm retains five; local probes, checkout, ref enumeration, ancestry, and object reads remain unbounded; no Git retry or backoff was added. Npm's separate 300-second token-bootstrap publication deadline is unchanged.

Both npm readback paths now write source package.json bytes only after the exact depth-one fetch and unbounded git show have completed and drained. The publish-side chain is split only at its existing artifact-download → Git-read → evidence-verification ordering, with the same artifact metadata, protected parent identity, and publication output contract.

Push-triggered plugin range discovery and ClawHub base-manifest history remain separately owned by their Node callers. This PR claims explicit workflow Git adoption only; those local owners remain a later serialized batch.

User Impact

There is no OpenClaw runtime behavior change. Release operators get deterministic plugin publication evidence: target SHAs, branch trust, exact package bytes, hashes, and publication routes are consumed only after every preceding Git process tree is verified extinct.

No release, npm/ClawHub publication, credentialed Git transport, remote tag mutation, version bump, changelog change, or credential-bearing release workflow was executed by this PR. Live proof uses disposable synthetic repositories and anonymous read-only GitHub transport.

Evidence

Live proof on a9b5770377474d02f7d8eb1b198ddd5cd6052b55: 23/23 actual YAML-policy scenarios passed against real Git 2.54.0 and Python 3.9.6, using disposable file:// bare repositories with no mocked Git, process owner, or clock. The proof covered main/release/alpha admission, uppercase preflight SHA, preflight alpha exclusion, untrusted commits, current/stale extended-stable tips, remote-only branch resolution, annotated/lightweight tags and protected-tooling binding, missing refs, and both source readback paths. CRLF, UTF-8, and trailing newlines remained byte-identical (SHA-256 e789b80a2d42ade9a3aef12f9534f5bf4a5ccb1974c97a0f8cc9c2cfe047bc47); missing blobs exited 128 without creating a readback file. Separately, an anonymous HTTPS ls-remote through the exact pinned owner matched the PR head, retaining an unbounded operation deadline. No publication credentials were used.

The first exact-head CI run failed eight report-owner batch cases at Corepack bootstrap, not plugin policy execution; Workflow Sanity passed. Commit 510eafd548cfef8424071fd09d4576b5c65cbf31 repairs the installed-tool owner: the batch runner now resolves installed Vitest through the existing resolver and runs it directly through the existing owned process launcher. The redundant pnpm exec hop, fixture bootstrap, and fake-pnpm tests are deleted. No network enablement, Corepack cache reader, dependency change, or new configuration is involved. Plugin workflow bytes are unchanged from the live-tested head.

Full runner proof also exposed two cancellation races. The project orchestrator no longer competes with its leaf's 100 ms force-kill timer, so it can join children and write the cancellation receipt. Vite/Rolldown's already-loaded signal-exit hook also needs the process kept alive while it reraises native SIGTERM, or a numeric 143 exit can win. Direct dependency source was inspected; pre-fix native cancellation failed three times, and the initial repaired batch and project paths each passed three times with native SIGTERM, a recorded cancellation, and the next sibling unstarted.

While this PR was validating, the performance-fixture repair landed the same signal-finalization fix using the existing waitForever primitive. The resulting real merge conflict was resolved by retaining both upstream finalizer files byte-for-byte and deleting this branch's alternative implementation. This PR now changes only the installed-Vitest launch and orchestrator lifetime; it does not carry a duplicate signal finalizer. The leaf kill budget and outer escape deadline are unchanged.

Final candidate: 030a37c1f9fab0d20e6e854b79412d24e01be5eb. The preceding rebased head passed CI 33326714005 and Workflow Sanity 33326714043, plus 382 runner and 644 workflow/routing tests. Its latest review accepted the preserved ref fallback but identified the direct batch launch's missing canonical Node flags.

That follow-up is fixed by calling the existing resolveVitestNodeArgs(params.env) before the installed CLI entrypoint. The real native-launch regression failed before the fix because default --no-maglev was absent; the explicit opt-in case passed. Both pass after the fix, including an opt-in supplied through the batch environment rather than the outer process. The complete runner proof now passes 383 tests (59 report-owner, 158 extension-runner, 128 Vitest-runner, 38 process-group), and scoped changed checks and fresh review of the correction passed. The complete preceding candidate and each subsequent correction received scoped-clean Codex review at the configured P0 threshold, not all-priority certification. Plugin workflow bytes remain identical to the 23-scenario live-tested version. The final head passed CI 33333690352, including the required openclaw/ci-gate, and Workflow Sanity 33333690343. No failing check remained in the final inspected rollup.

A subsequent CI run on the Node-flag correction failed the first desktop-shutdown case with one unexpected active Gateway admission. Investigation found a separate, deterministic shared-runner lifecycle gap: Gateway admission is process-global but is not registered for generic singleton teardown, so module invalidation could carry its roots and fences into another test file.

The shared runner now fences already-suspended admission waiters before existing asynchronous cleanup, then uses the canonical admission reset after lifecycle/DOM teardown and before module invalidation. The ordered native producer/observer regression failed with the same expected-0/received-1 state before repair; it also caught a reset-only partial repair reopening an old waiter. The final regression verifies old waiter rejection, stale continuation rejection, zero carried roots, and fresh admission. No production Gateway code, shutdown assertion, test deadline, or retry policy changed.

Final proof for that cleanup: the real child-Vitest regression passed all 36 behavior fixtures with only its intentionally failing collection fixture; mock-resolution siblings passed 7/7; unchanged desktop-shutdown cases passed 6/6; and the frozen 196-file/two-worker selection at exact failed CI merge d4691eb4483bda764e8c7e1453db9b38aa0832c8 passed 2,929 tests with the scoped repair applied. Final changed checks and fresh full-candidate scoped autoreview passed. The original CI producer is still unattributed: unmodified local shard and ordering probes also passed, so this is a demonstrated file-boundary repair, not a claim to have identified every unfinished asynchronous operation.

A second real merge conflict arose when the diagnostic lifecycle repair independently added the basic admission reset. The final candidate rebases onto d37f9a1ad68359e7f4256bf6e4ec4602eb32806d, retains the upstream root/draining assertions, reuses its fixture path, and keeps exactly one late reset plus the early suspended-waiter fence. The runner and both publication workflow files remain byte-identical to the previously tested 8251b2a7fa5bf76b13aa749448dd74caa75fc27d versions. On the composed tree, the ordered child-runner regression, 7 mock-resolution tests, 6 unchanged shutdown tests, changed gates, and fresh complete-candidate scoped autoreview passed. The final head then passed 876 tests across five workflow/routing suites, including all 80 plugin lifecycle cases and 233 observed extinction boundaries; all fixture cleanup completed. Two Linux-only workflow guards were skipped on macOS. Fresh 23/23 real-Git actual-YAML scenarios and anonymous HTTPS exact-head readback also passed. Exact-head hosted CI and Workflow Sanity are green; the conflicting head's missing CI was never treated as passing proof.

Final workflow/routing command:

node scripts/run-vitest.mjs run --config test/vitest/vitest.tooling.config.ts --configLoader runner test/scripts/plugin-release-git-lifecycle.test.ts test/scripts/plugin-npm-extended-stable-workflow.test.ts test/scripts/ci-workflow-guards.test.ts test/scripts/package-acceptance-workflow.test.ts test/scripts/test-projects.test.ts --reporter=dot
  • Pre-fix RED: all four existing ClawHub/npm ref-resolution and trust bodies failed because real fake-Git parent/child/grandchild writers crossed continuation, output, or exit boundaries.
  • Complete plugin publication lifecycle matrix: 80 passed. It covers exact argv/refspec/depth; bounded and unbounded operations; ordinary 124/125/143; timeout; setup/cleanup failure; cancellation; local-to-origin target fallback; protected tags; main/release/alpha ordering; extended-stable exact-tip admission; enumeration errors; exact source bytes; partial-output rejection; and readback consumer fences.
  • Plugin npm workflow contracts: 13 passed.
  • Package acceptance workflow contracts: 214 passed.
  • Changed-scope split: 124 scope tests passed; focused workflow/routing proof passed after the explicit owner-test ordering update.
  • Broad shared-owner run: plugin publication, simple release, core owner, and Linux owner suites passed. Nine existing Performance fixture cases hit their 55-second readiness deadline late in the 55-minute serial run; the exact failed selection passed 10/10 immediately in isolated rerun, so no timeout or fixture assertion was weakened.
  • Post-rebase proof: 80 lifecycle cases and 45 focused workflow/routing cases passed on a9b57703774.
  • Full changed-surface gate passed conflict, line/assertion ratchets, dependency and ownership guards, formatting, core/script/test typechecks, dead-export checks, and core/script lint.
  • actionlint, parsed non-migrated workflow equivalence, docs inventory, no-direct-Git checks, git diff --check, targeted formatting, and mandatory autoreview passed with no accepted finding.
  • The repository Python workflow checker is locally blocked because this machine's configured package index does not provide pre-commit==4.6.2. No dependency or pin was changed; exact-head Workflow Sanity 33333690343 passed as the authoritative hosted check.

Final candidate validation for the runner repair:

  • Latest full report-owner, extension-runner, Vitest-runner, and process-group suites: 383 passed (59 + 158 + 128 + 38), including default Node flags and explicit Maglev opt-in.
  • Independent lead rerun of all report-owner tests through the normal wrapper with package-manager bootstrap unavailable and network disabled: 59 passed.
  • Real Corepack 0.35 → pnpm 12.1 → repository-wrapper invocation, with a disposable prepared cache and isolated HOME/network disabled: 10 batch cases passed, including all eight cases that failed hosted CI.
  • Real batch fork/thread namespace cleanup: 2 passed, 21 outside the selected filter skipped.
  • Scoped changed checks for all six runner-repair files passed types, lint, formatting, and guards. Fresh full-candidate Codex autoreview returned scoped-clean at its configured P0 threshold; this is not a claim of all-priority certification.

Commands for the focused runner proof:

node scripts/run-vitest.mjs run --config test/vitest/vitest.tooling.config.ts --configLoader runner test/scripts/vitest-report-owner.test.ts test/scripts/test-extension.test.ts test/scripts/run-vitest.test.ts test/scripts/vitest-process-group.test.ts
env -u npm_execpath -u COREPACK_HOME COREPACK_ENABLE_NETWORK=0 node scripts/run-vitest.mjs test/scripts/vitest-report-owner.test.ts --no-file-parallelism --reporter=dot
node scripts/run-vitest.mjs run --config test/vitest/vitest.tooling.config.ts --configLoader runner test/scripts/run-vitest-state-cleanup.test.ts -t 'batch.*cleans its namespace'
node scripts/check-changed.mjs -- scripts/lib/vitest-batch-runner.mts scripts/lib/test-projects-delegation.mts scripts/test-extension-batch.mts scripts/test-projects.mts test/scripts/vitest-report-fixture.ts test/scripts/test-extension.test.ts

The late resolver finding is addressed in the source-backed review disposition. The fallback policy is deliberately preserved, not treated as new publication authority. Documentation now distinguishes ordinary probe fallback from terminal ancestry/owner failures and names the unconditional versus optional fetches accurately. The existing cancellation/cleanup test now exercises the local verification probe with an available origin candidate and forbids a second matching operation. The complete 80-case lifecycle matrix passed again, the two-file changed gate passed, and fresh Codex autoreview of that refinement returned scoped-clean at the configured P0 threshold. No production workflow bytes changed.

Commands for the final shared-runner cleanup proof:

node scripts/run-vitest.mjs run --config test/vitest/vitest.tooling.config.ts --configLoader runner test/non-isolated-runner.test.ts --reporter=dot
node scripts/run-vitest.mjs run --config test/vitest/vitest.unit-fast.config.ts --configLoader runner test/non-isolated-runner.resolve-mocks.test.ts --reporter=dot
node scripts/run-vitest.mjs run --config test/vitest/vitest.gateway-core.config.ts --configLoader runner src/gateway/worker-environments/computer-transport.shutdown.test.ts --reporter=dot
node scripts/check-changed.mjs -- test/non-isolated-runner.ts test/non-isolated-runner.test.ts

The full snapshot proof used scripts/ci-run-node-test-shard.mts with the linked failed job's original OPENCLAW_NODE_TEST_GROUPS_JSON and two-worker setting. Every selected file was required to exist; the missing-on-branch queued-collector test was preserved by applying only the two-file repair to the exact CI merge snapshot.

Production/workflow/tooling LOC: +450/-153 (net +297). Tests and test support, including the changed-test routing support: +973/-306 (net +667). Documentation: +3/-1 (net +2). Total: +1426/-460 across 21 files; the test split includes a pure 45-line move, not new behavior. Product application runtime is unchanged.

Production growth is concentrated in the plugin workflow migration (+431/-133, net +298): four pinned owner placements, typed workflow-owned decisions, and two exact-byte readback owners. Keeping these policies in trusted workflow source prevents selected publication-source code from choosing its own owner or admission policy. The shared supervisor is reused unchanged; there is no new supervisor, retry layer, or generic release-policy framework. After reusing the upstream signal finalizers and canonical Node flags, the installed-Vitest repair is production/tooling net negative (+18/-19, net -1) and removes 73 net test/support lines. After composing with current main's independently added basic admission reset, the remaining shared-runner admission repair adds 45 net test/support lines, with no production runtime change.

@clawsweeper

clawsweeper Bot commented Aug 30, 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 docs Improvements or additions to documentation scripts Repository scripts size: XL labels Aug 30, 2026
@steipete
steipete marked this pull request as ready for review August 30, 2026 16:11
@openclaw-barnacle openclaw-barnacle Bot added the maintainer Maintainer-authored PR label Aug 30, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. 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 30, 2026
@clawsweeper

clawsweeper Bot commented Aug 30, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 30, 2026, 4:36 PM ET / 20:36 UTC.

ClawSweeper review

What this changes

The PR replaces direct Git commands in plugin ClawHub and npm publication workflows with the shared drained-process owner, adds exact-source readback fencing, and updates runner lifecycle coverage.

Regression provenance

Possible regression — probable (reviewed change; failure trace). No predecessor PR is attributed.

Merge readiness

⚠️ Ready for maintainer review - 3 items remain

No introduced correctness or security defect was found, but this maintainer-authored, security-sensitive publication-workflow change should remain open for exact-head CI completion and release-owner review.

Priority: P2
Reviewed head: 030a37c1f9fab0d20e6e854b79412d24e01be5eb
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The patch has focused owner-boundary coverage and no supported correctness finding; exact-head CI and release-owner review remain before merge.
Proof confidence 🌊 off-meta tidepool Not applicable: The repository state identifies this as a MEMBER-authored PR, so the external-contributor proof gate does not apply; its supplied synthetic Git and native-runner evidence remains supplemental while exact-head CI is pending.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The repository state identifies this as a MEMBER-authored PR, so the external-contributor proof gate does not apply; its supplied synthetic Git and native-runner evidence remains supplemental while exact-head CI is pending.
Evidence reviewed 5 items Shared owner boundary: The composite action copies the pinned owner outside the checkout and exports its path; the owner drains its process group before returning a Git result.
Workflow trust behavior: The introduced workflows use that owner for Git operations; ClawHub resolution retains its pre-existing local-to-origin fallback while ancestry treats only exit 1 as a non-membership result.
Readback and failure coverage: The new lifecycle suite covers failed fetch/show operations, cleanup and cancellation fences, ancestry/enumeration errors, and source-package byte readback before later consumers run.
Findings None None.
Security None None.

How this fits together

Plugin publication workflows fetch repository state, verify a publish target, then pass package metadata to npm or ClawHub publication steps. The shared Git owner is the process boundary between Git execution and later trust, hashing, and publication decisions.

flowchart LR
  A[Release dispatch] --> B[Plugin publication workflow]
  B --> C[Shared Git process owner]
  C --> D[Fetch and inspect repository state]
  D --> E[Trust and artifact validation]
  E --> F[Publication route]
  C --> G[Process cleanup and cancellation fence]
Loading

Decision needed

Question Recommendation
Does a release-workflow owner approve using the pinned shared Git owner as the enforcement boundary for plugin-publication trust and readback after exact-head CI completes? Approve the shared owner boundary: After exact-head CI is green, accept the tested shared owner as the canonical lifecycle boundary for these plugin publication paths.

Why: The patch changes OIDC-adjacent publication admission and is labeled for maintainer handling; source review can assess implementation but cannot substitute for release-owner acceptance of that enforcement boundary.

Before merge

  • Resolve merge risk (P1) - This adds 297 net workflow/tooling lines to OIDC-adjacent publication trust and artifact-readback paths; the source review supports the chosen owner boundary, but this release-sensitive change still needs exact-head CI and human approval before merge.
  • Complete next step (P2) - The remaining gate is exact-head CI plus release-owner acceptance of a security-sensitive workflow boundary, not a mechanical repair.
Agent review details

Security

None.

PR surface

Tests +651, Docs +2, Config +298, Other +15. Total +966 across 21 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 14 953 302 +651
Docs 1 3 1 +2
Config 2 431 133 +298
Generated 0 0 0 0
Other 4 39 24 +15
Total 21 1426 460 +966

Review metrics

Metric Value Why it matters
Production versus test delta workflow/tooling +297, docs +2, tests/test-support +667 The production growth is concentrated in explicit Git lifecycle and trust-policy ownership; the large companion test delta exercises process and readback boundaries.

Root-cause cluster

Relationship: partial_overlap
Canonical: #132183
Summary: This PR explicitly addresses the plugin-publication portion of the wider Git-process lifecycle campaign; other workflow callers remain outside its stated scope.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge-risk options

Maintainer options:

  1. Complete exact-head trust validation (recommended)
    Keep the PR open until its current head has completed CI and a release-workflow owner accepts the tested OIDC-adjacent trust boundary.
  2. Pause for policy redesign
    Pause this branch if maintainers do not want the shared owner to be the permanent policy-execution boundary for plugin publication.

Technical review

Best possible solution:

Retain the single drained Git-owner boundary, merge only after exact-head CI and release-workflow review confirm the protected publish and normal publish paths; the added policy cannot be absorbed into selected source checkouts without weakening the trusted-policy boundary.

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

Yes, source-reproducible: the dedicated lifecycle suite names the process-tree, cancellation, ancestry, and readback failure cases at the changed owner boundary, though this review did not execute it.

Is this the best way to solve the issue?

Yes: routing Git through the existing isolated owner preserves the workflow-specific trust checks while ensuring results are not consumed before process cleanup.

AGENTS.md: found and applied where relevant.

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

Labels

Label justifications:

  • P2: The change affects release-operator publication workflows but has no demonstrated active user-facing outage.
  • merge-risk: 🚨 security-boundary: The PR changes the Git execution and trust-validation boundary preceding OIDC-enabled plugin publication.
  • 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 repository state identifies this as a MEMBER-authored PR, so the external-contributor proof gate does not apply; its supplied synthetic Git and native-runner evidence remains supplemental while exact-head CI is pending.

Evidence

What I checked:

Likely related people:

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

Rank-up moves

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

  • Wait for the current head's CI to complete, then obtain release-workflow approval for the OIDC-adjacent boundary.

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 (6 earlier review cycles)
  • reviewed 2026-08-30T16:19:38.669Z sha a9b5770 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-30T17:11:23.390Z sha a9b5770 :: found issues before merge. :: [P1] Fail closed on non-absence ref verification failures
  • reviewed 2026-08-30T17:35:57.807Z sha 510eafd :: found issues before merge. :: [P1] Fail closed on non-absence ref verification failures
  • reviewed 2026-08-30T18:07:35.281Z sha 447374c :: found issues before merge. :: [P2] Preserve Vitest’s default Node flags
  • reviewed 2026-08-30T18:34:16.113Z sha bbfbbd7 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-30T20:15:47.983Z sha 8251b2a7fa5bf76b13aa749448dd74caa75fc27d :: needs maintainer review before merge. :: none

@clawsweeper clawsweeper Bot added merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. P1 High-priority user-facing bug, regression, or broken workflow. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed P2 Normal backlog priority with limited blast radius. 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 30, 2026
@steipete

steipete commented Aug 30, 2026 •

Copy link
Copy Markdown
Contributor Author

The late resolver P1 was checked against the raw parent, current workflow, downstream publication gates, and canonical owner. I am retaining the existing fallback contract, not accepting it as an introduced trust bypass.

The pre-migration resolver already used if local rev-parse; elif origin rev-parse: any ordinary nonzero local probe could try origin. The migration's typed GitFailure catch preserves that caller behavior, as required by this lifecycle campaign. Restricting it to status 1 would be a separate policy change.

Resolution is not publication authorization. The selected commit must still pass workflow-SHA or protected exact-tag binding, then independent main/release/matching-alpha ancestry, before the exact-SHA pack and environment-approved publication chain. Only ancestry status 1 advances to another trust source; enumeration failure is terminal.

The canonical owner raises ordinary GitFailure only after verified drain and cancellation checks. Cleanup/inspection/setup exceptions and latched cancellation are not caught by the resolver. In particular, ordinary Git exits 125/143 are not the same in-process outcomes as owner failure/cancellation, despite sharing final shell numbers.

The review did identify an overbroad docs sentence. It is corrected to distinguish resolver fallback from ancestry admission, and to name the unconditional main/release versus optional release-tag fetch accurately. The existing terminal test now injects failure/cancellation inside the local verification probe with an available origin candidate, and checks that no second matching probe occurs. All 80 lifecycle cases passed again, the changed gate passed, and fresh autoreview of the refinement was scoped-clean at its configured P0 threshold. No workflow policy or timeout changed.

The rebase candidate was pushed at 447374cf3e9ddeb24e23b763fcfb43f38673fafd. A real conflict with the independently landed signal-finalization repair in PR #133356 was resolved by keeping both upstream finalizer files byte-identical and dropping our alternative. The combined candidate passed all 382 runner tests, including native cancellation, plus 644 workflow/routing tests and fresh full-candidate autoreview. Fresh exact-head CI remains required before merge.

The production-growth concern is also accounted for: net +298 is confined to workflow-owned typed policy, four pinned owner placements, and two exact-byte readback boundaries. Moving those policies into the selected publication source would break the trusted-policy boundary; the shared supervisor remains unchanged. After reusing the upstream finalizers and canonical Node flags, the installed-Vitest runner repair is production/tooling net -1, so the whole PR is net +297 production/tooling lines. It removes the redundant package-manager bootstrap rather than adding a cache or network workaround.

A subsequent review accepted the preserved resolver contract and raised a separate P2 about batch Node defaults. That is fixed in bbfbbd75eb0a19e2baa2ed3ef658a67fd4c70fb7: the direct batch launch now calls existing resolveVitestNodeArgs(params.env). The real default case failed before the fix with missing --no-maglev, while explicit opt-in passed; both now pass, including caller-supplied environment handling. All 383 runner tests, scoped changed checks, and fresh scoped autoreview passed. The prior head's CI33326714005 and Workflow Sanity33326714043 were green; each subsequent head required its own successful CI.

Final land-ready head: 030a37c1f9fab0d20e6e854b79412d24e01be5eb. Exact-head CI 33333690352, its required openclaw/ci-gate, and Workflow Sanity 33333690343 passed. Fresh local proof passed 23 actual-YAML real-Git scenarios, anonymous credentialless HTTPS exact-head readback, and 876 workflow/routing tests including all 80 lifecycle cases and 233 extinction boundaries. Two Linux-only guards were skipped on macOS; no assertion or deadline was weakened. Exact commands are in the updated PR body.

The intervening CI failure also exposed a deterministic shared-runner admission lifecycle gap. The final cleanup fences already-suspended waiters before asynchronous teardown, then retires old roots/continuations with one canonical late reset. It composes with the independently landed basic reset, retaining upstream tests and deleting duplication. Ordered child-runner proof passed all 36 behavior fixtures; mock-resolution 7/7 and unchanged desktop-shutdown 6/6 passed. The original frozen CI selection passed 2,929 tests with this same runner repair. The original CI producer remains unattributed: this proves file-boundary cleanup, not comprehensive orphan-task joining. Fresh composed-tree checks and complete-candidate scoped autoreview passed at the configured P0 threshold.

The latest exact-head review has no actionable correctness/security finding. Its requested conflict reconciliation and exact-head workflow/lifecycle proof are complete. Release-owner authority for the explicit maintainer-directed landing was verified, as were CODEOWNERS and live main rules: the required CI gate is satisfied and no additional independent-review rule is enforced. This accepts the existing publication trust policy, not new publication authority; workflow/tag binding, ancestry, immutable evidence, and environment approval remain intact. Proceeding through native prepare/merge, with no registry publication or release.

@steipete
steipete force-pushed the steipete/git-owner-plugin-release branch from 6f3f4c2 to 447374c Compare August 30, 2026 17:58
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. 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. and removed P1 High-priority user-facing bug, regression, or broken workflow. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Aug 30, 2026
Remove the redundant pnpm bootstrap and keep orchestration alive until child cleanup and cancellation report completion. Preserve native signal termination across Vite's signal-exit hook.
Document the preserved ordinary probe fallback separately from trust admission. Exercise terminal cleanup and cancellation inside that probe and forbid repeated matching operations.
Use the existing Vitest Node-argument resolver with the supplied batch environment. Exercise default and explicit Maglev opt-in behavior through the real installed CLI with no package-manager PATH.
Fence suspended admission waiters before existing asynchronous cleanup, then retire prior roots and reopen admission before module invalidation. Prove the boundary with ordered native producer/observer fixtures without changing Gateway runtime or shutdown assertions.
@steipete
steipete force-pushed the steipete/git-owner-plugin-release branch from 8251b2a to 030a37c Compare August 30, 2026 20:27
@steipete
steipete merged commit 50b675f into main Aug 30, 2026
184 checks passed
@steipete
steipete deleted the steipete/git-owner-plugin-release branch August 30, 2026 20:49
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 31, 2026
…claw#133368)

* ci: own plugin publication Git lifecycle

* fix(testing): run offline batches with installed Vitest

Remove the redundant pnpm bootstrap and keep orchestration alive until child cleanup and cancellation report completion. Preserve native signal termination across Vite's signal-exit hook.

* test(ci): clarify plugin ref fallback ownership

Document the preserved ordinary probe fallback separately from trust admission. Exercise terminal cleanup and cancellation inside that probe and forbid repeated matching operations.

* fix(testing): honor canonical Node flags in batches

Use the existing Vitest Node-argument resolver with the supplied batch environment. Exercise default and explicit Maglev opt-in behavior through the real installed CLI with no package-manager PATH.

* test: retire gateway admission between files

Fence suspended admission waiters before existing asynchronous cleanup, then retire prior roots and reopen admission before module invalidation. Prove the boundary with ordered native producer/observer fixtures without changing Gateway runtime or shutdown assertions.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to documentation maintainer Maintainer-authored PR merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. scripts Repository scripts size: XL 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