Skip to content

fix(update): inspect collected legacy service handoffs - #166232

Merged
RomneyDa merged 1 commit into
mainfrom
fix/frv-legacy-update-inspection
Oct 6, 2026
Merged

RomneyDa merged 1 commit into
mainfrom
fix/frv-legacy-update-inspection

Conversation

@RomneyDa

@RomneyDa RomneyDa commented Oct 6, 2026 •

Copy link
Copy Markdown
Member

Problem

Full Release Validation's published-driver compatibility lane for 2026.9.3 → candidate deterministically refused candidate validation with managed-service-preflight.

The shipped 2026.9.2/2026.9.3 updater handoff predates serviceManagerUid. After that updater stops a Linux native service, systemd may collect the unit before the candidate reinspects it. Candidate validation then lacks the manager boundary needed to load the collected unit and treats the managed service as unavailable.

Solution

For a verified Linux handoff that is already stopped, has a captured service environment, and omits the newer manager UID, retain the running installed updater account as the native manager boundary. Explicit recorded manager identity continues to take precedence.

This is limited to legacy stopped handoffs under the existing current-authority assertion.

Evidence

  • New regression: collected systemd unit from a shipped stopped handoff retains the installed updater's manager UID.
  • Identity suite: 4/4 passed; 24.6s cold invocation, new test 9ms.
  • Service-maintenance siblings: 42/42 passed.
  • Service-fingerprint siblings: 30/30 passed.
  • Core production typecheck passed.
  • The simulated Linux effective UID is installed and restored portably for Windows test hosts.
  • Targeted formatting and git diff --check passed.
  • AutoReview P0/P1: scoped clean.

FRV source: https://github.com/openclaw/openclaw/actions/runs/37502933059

  • Exact hosted published-driver proof: CI run 37513855606, job 112445769676 passed the immutable candidate artifact from exact head d0f62baf965bd63f05a12e6ac41e0959753e6659 through the shipped openclaw@latest stable driver (2026.9.8). The update finished with readiness 200 and verified the running candidate version; the only unrelated run failure was the inherited MCP dependency audit.

@clawsweeper

clawsweeper Bot commented Oct 6, 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.

@openclaw-barnacle openclaw-barnacle Bot added cli CLI command changes size: S labels Oct 6, 2026
@RomneyDa

RomneyDa commented Oct 6, 2026

Copy link
Copy Markdown
Member Author

@clawsweeper automerge

@clawsweeper

clawsweeper Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

ClawSweeper 🐠 automerge status

This pass ended as a no-op: no narrow repair surfaced, so ClawSweeper left the branch untouched.

Executor outcome: no planned fix actions.
Worker summary: The adopted PR merged before preflight and its fix is present on current main. No branch repair, replacement PR, or GitHub mutation is needed.

Worker actions:

  • keep_closed on this PR: skipped - Already merged on current main; the repair request is obsolete. Preserve RomneyDa's existing PR and commit credit.
  • keep_closed on #164997: skipped - Already-closed historical context; no action is required.

No branch push, rebase, replacement PR, merge, or ClawSweeper re-review was started on this pass.

fish notes: reasoning medium; reviewed against d0f62ba.

Automerge progress:

  • 2026-10-06 18:02:52 UTC active review reused b7d27fbcd009 (waiting)
  • 2026-10-06 18:02:52 UTC review queued b7d27fbcd009 (queued)
  • 2026-10-06 18:11:52 UTC review queued d0f62baf965b (queued)

@clawsweeper clawsweeper Bot added the clawsweeper:automerge Maintainer opted this PR into bounded ClawSweeper-reviewed automerge label Oct 6, 2026
@RomneyDa RomneyDa added the ci:no-fail-fast Keep all selected CI matrix jobs running after failures on the next PR run. label Oct 6, 2026
@clawsweeper

clawsweeper Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed October 6, 2026, 2:16 PM ET / 18:16 UTC (Revision 2).

ClawSweeper review

What this changes

The PR lets candidate update validation inspect collected Linux service units from older stopped handoffs by using the installed updater’s account when no manager UID was recorded.

Merge readiness

⛔ Blocked before merge - 2 items remain

The revised head resolves both prior code findings and remains useful against pinned main. No new actionable defect was found, but the required published-driver upgrade result is still unverified.

Priority: P2
Reviewed head: d0f62baf965bd63f05a12e6ac41e0959753e6659

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The focused patch resolves the earlier defects, while required production upgrade evidence remains incomplete.
Proof confidence 🦐 gold shrimp (3/6) Not applicable: Real behavior proof is not required for maintainer- or bot-authored pull requests.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: Real behavior proof is not required for maintainer- or bot-authored pull requests.
Evidence reviewed 7 items Pinned introduction and continuing necessity: The introduced delta adds the legacy stopped-handoff UID fallback; pinned main passes only the recorded serviceManagerUid. Main therefore does not already implement this repair.
Prior findings resolved: The expected-service contract now accepts an optional stopped marker, preserving existing callers. The test installs and restores process.geteuid using its original property descriptor, including hosts where the property was absent. Reported typecheck and test results are contributor evidence, not checks executed by this review.
Authority reaches the production boundary: The fallback still flows through the native operation lock and current-authority assertion. The systemd command reader authenticates the manager UID and targets its unique owner before LoadUnit; retained-peer queries also enforce the selected unit and current authority. No concrete unauthorized-manager or stale-authority bypass was found.
Findings None None.
Security None None.

How this fits together

OpenClaw’s updater reinspects the managed Gateway service before candidate validation and service maintenance. Its service reader authenticates the selected systemd manager and checks the retained service definition before allowing further update work.

flowchart TD
  A[Installed updater handoff] --> B[Candidate service inspection]
  B --> C[Recorded manager UID available]
  C -->|Yes| D[Use recorded identity]
  C -->|Legacy stopped handoff| E[Use updater account]
  D --> F[Authenticate systemd manager and current authority]
  E --> F
  F --> G[Inspect collected unit metadata]
  G --> H[Revalidate service ownership]
Loading

Before merge

  • Resolve merge risk (P1) - The repaired candidate has not been shown completing the existing published-driver compatibility scenario after systemd collects the stopped unit; the regression mocks do not establish that upgrade behavior.
  • Complete next step (P2) - Record the patched published-driver compatibility result for the collected stopped unit before merge.
Agent review details

Security

None.

PR surface

Source +15, Tests +78. Total +93 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 1 17 2 +15
Tests 1 78 0 +78
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 95 2 +93

Review metrics

None.

Merge-risk options

Maintainer options:

  1. Verify the patched upgrade cell (recommended)
    Record the existing 2026.9.3 published-driver compatibility cell against a candidate containing this repair before merging.

Technical review

Best possible solution:

Preserve the narrow fallback and existing manager authentication, with a recorded successful published-driver upgrade through the collected-unit path.

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

Yes, from source: a stopped legacy handoff without a manager UID cannot enable collected-unit loading on pinned main. The linked compatibility job failed, but this review did not execute the upgrade or inspect its detailed logs.

Is this the best way to solve the issue?

Yes, the fallback is narrowly limited to legacy stopped Linux handoffs and preserves explicit manager identity and existing authority checks; production upgrade confirmation remains necessary.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 10334ec913d7.

Labels

Label changes:

  • add P2: This is a focused compatibility repair for older Linux updater handoffs, with no evidence of a broad current outage.
  • add merge-risk: 🚨 compatibility: The changed legacy-upgrade path lacks the published-driver result required to establish that stopped-service recovery works after the repair.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • add status: 🚀 automerge armed: This PR is in ClawSweeper's automerge lane. Not applicable: Real behavior proof is not required for maintainer- or bot-authored pull requests.

Label justifications:

  • P2: This is a focused compatibility repair for older Linux updater handoffs, with no evidence of a broad current outage.
  • merge-risk: 🚨 compatibility: The changed legacy-upgrade path lacks the published-driver result required to establish that stopped-service recovery works after the repair.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 🚀 automerge armed: This PR is in ClawSweeper's automerge lane. Not applicable: Real behavior proof is not required for maintainer- or bot-authored pull requests.

Evidence

What I checked:

  • Pinned introduction and continuing necessity: The introduced delta adds the legacy stopped-handoff UID fallback; pinned main passes only the recorded serviceManagerUid. Main therefore does not already implement this repair. (src/cli/update-cli/update-command-service-maintenance.ts:312, d0f62baf965b)
  • Prior findings resolved: The expected-service contract now accepts an optional stopped marker, preserving existing callers. The test installs and restores process.geteuid using its original property descriptor, including hosts where the property was absent. Reported typecheck and test results are contributor evidence, not checks executed by this review. (src/cli/update-cli/update-command-service-maintenance-identity.test.ts:29, d0f62baf965b)
  • Authority reaches the production boundary: The fallback still flows through the native operation lock and current-authority assertion. The systemd command reader authenticates the manager UID and targets its unique owner before LoadUnit; retained-peer queries also enforce the selected unit and current authority. No concrete unauthorized-manager or stale-authority bypass was found. (src/cli/update-cli/update-command-service-plan.ts:288, d0f62baf965b)
  • Upgrade evidence does not cover the patched candidate: The supplied FRV link identifies run 37502933059 at workflow head 5ba835e. Its update-first-hop-compat-2026.9.3 job failed; the captured PR body supplies mocked regression results but no observed patched published-driver recovery. The run’s logs redirect to a host blocked by the reviewer network policy, so detailed failure logs were not inspected.
  • Applicable update proof requirement: The fully read root policy requires update repairs to be demonstrated with a published-driver × candidate cell. No scoped ancestor policy or matching maintainer-notes directory was present for these paths. (AGENTS.md, d0f62baf965b)
  • Related merged history and routing: Git history identifies recent update-service work by Peter Steinberger. GitHub verifies steipete authored the merged fix(update): keep retained service authority after a stopped-free inspection and let repair retire untouched preparations #164997, whose patch retained authority during inspection when assertCurrent is supplied. That work supports this repair but does not implement its missing-UID fallback. (src/cli/update-cli/update-command-service-maintenance.ts:328, 94975271e351)

Likely related people:

  • unknown: The claimed source-line change could not be verified from bounded local history. (role: source history unknown; confidence: low)

Rank-up moves

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

  • Record redacted terminal output or logs showing the patched candidate completes the existing published-driver collected-unit compatibility scenario.

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-10-06T18:07:21.873Z sha b7d27fbcd009277d53df0265c94909237ab82a2e :: blocked before merge. :: [P2] Include the stopped marker in the expected-service contract | [P2] Provide a portable effective-UID fixture

@RomneyDa
RomneyDa force-pushed the fix/frv-legacy-update-inspection branch from b7d27fb to d0f62ba Compare October 6, 2026 18:10
@RomneyDa

RomneyDa commented Oct 6, 2026

Copy link
Copy Markdown
Member Author

@clawsweeper automerge

@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 🚀 automerge armed This PR is in ClawSweeper's automerge lane. clawsweeper:human-review Needs maintainer review before ClawSweeper can continue labels Oct 6, 2026
@clawsweeper

clawsweeper Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

🦞✅
ClawSweeper is pausing this repair loop for human review.

Source: clawsweeper[bot]
Reason: - [ ] Resolve merge risk (P1) - The repaired candidate has not been shown completing the existing published-driver compatibility scenario after systemd collects the stopped unit; the regression mocks do not establis... (sha=d0f62baf965bd63f05a12e6ac41e0959753e6659)

Why human review is needed:
ClawSweeper found a blocker that should be resolved or accepted by a maintainer before the repair or automerge loop continues.

What the maintainer can do as a next step:
If the maintainer accepts the current risk and wants ClawSweeper to continue merge gates, comment @clawsweeper approve. If more work is needed, resolve the blocker first, then comment @clawsweeper automerge to re-review and continue. If automation should stay paused, leave clawsweeper:human-review in place or comment @clawsweeper stop.

I added clawsweeper:human-review and left the final call with a maintainer.

@RomneyDa

RomneyDa commented Oct 6, 2026

Copy link
Copy Markdown
Member Author

The package-only release-check dispatch built the exact candidate successfully in 23m26s, then failed before tests because that narrow dispatch did not produce the immutable prerelease-plugin registry tuple required by package acceptance. No update test ran. Exact-head CI release-gate qualification is now running at https://github.com/openclaw/openclaw/actions/runs/37513334175; the changed update-cli path selects the published-driver update cell against npm latest (the shipped stable driver) without the unrelated package-acceptance transport mismatch.

@RomneyDa

RomneyDa commented Oct 6, 2026

Copy link
Copy Markdown
Member Author

@clawsweeper approve

Exact compatibility proof is complete: CI run 37513855606 job 112445769676 passed the shipped stable openclaw@latest driver (2026.9.8) to the immutable candidate built from exact head d0f62ba. The real update finished, returned readyz=200, and verified the running candidate version. The only run failure is the inherited MCP dependency audit.

@RomneyDa

RomneyDa commented Oct 6, 2026

Copy link
Copy Markdown
Member Author

Landing via the native inherited-red admin exception. ClawSweeper accepted maintainer approval for exact head d0f62baf965bd63f05a12e6ac41e0959753e6659; the hosted published-driver boundary passed from shipped stable 2026.9.8 to this candidate with readiness 200 and running-version verification. The remaining required failure is the pre-existing MCP production audit, unrelated to this repair.

@RomneyDa
RomneyDa merged commit 76beb56 into main Oct 6, 2026
287 of 298 checks passed
@RomneyDa
RomneyDa deleted the fix/frv-legacy-update-inspection branch October 6, 2026 19:12
vincentkoc added a commit that referenced this pull request Oct 6, 2026
* commit 'c39d9b0692dbaafa5b1bfe02514c9f6411ab5546': (30 commits)
  fix(ci): clear MCP audit and service-worker test blockers (#166217)
  test(gateway): wait for steering admission in FIFO fixtures
  fix(llama-cpp): managed setup crashes and loops on macOS below 13.3 (#163358)
  perf(worktrees): avoid full session parsing during GC (#166072)
  fix(update): recover stopped legacy managed services (#166232)
  perf(gateway): stream bounded link preview metadata (#166195)
  perf(diagnostics): release completed Git operation state (#166214)
  chore(deps): update fs-safe to 0.24.1 and clone plugin source captures (#166189)
  feat(clients): adopt worker-local inference placement (#163647)
  test: serialize PowerShell completion process suites (#166229)
  test: stabilize release timing boundaries (#166218)
  refactor(sessions): persist run outcomes only; liveness comes from the run registry (#165733)
  test(gateway): prove mention refresh after config retargeting
  fix(team-reports): keep the missed closed day when catch-up runs after midnight (#165780)
  test(gateway): join WebChat queue admission and drain completion
  fix(logging): reject blank diagnostic stability query fields (#145532)
  fix(agents): report unparseable serialized edit arguments (#163577)
  improve(anthropic): log Claude Code version probe failures (#157697)
  fix(agents): clarify prompt-size provider failures (#159712)
  fix(memory): re-throw non-ENOENT/ENOTDIR errors in root memory file lookup (#107921)
  ...
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:no-fail-fast Keep all selected CI matrix jobs running after failures on the next PR run. clawsweeper:automerge Maintainer opted this PR into bounded ClawSweeper-reviewed automerge clawsweeper:human-review Needs maintainer review before ClawSweeper can continue cli CLI command changes merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P2 Normal backlog priority with limited blast radius. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: S status: 🚀 automerge armed This PR is in ClawSweeper's automerge lane.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant