Skip to content

fix: keep plugin state available when a write is refused - #190320

Merged
vincentkoc merged 1 commit into
mainfrom
fix/plugin-state-unstarted-publication-20261101
Nov 1, 2026
Merged

vincentkoc merged 1 commit into
mainfrom
fix/plugin-state-unstarted-publication-20261101

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Nov 1, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

Fixes plugin state becoming unavailable after a write loses its owner before the database worker receives it. A refused write could invalidate prepared readers and make later operations fail despite leaving stored data untouched.

User Impact

A write rejected before dispatch preserves the previously published state. Writes with an unknown native outcome still invalidate it. No configuration changes or migration are required.

Why This Change Was Made

The broker retains publication admission before its final owner check. If that check fails, the broker knows the operation never entered the worker, but finish observers previously received no native settlement and classified it as unknown. Pass that no-entry fact through admission finish, drain queued native evidence first, and publish confirmed no-effect settlement only when no native evidence exists. The operation still rejects with its original error.

Cron approval and session-upstream publication now use the shared finish observer so they preserve the same signal. Existing receipt-required policies in other publication domains are unchanged. Production delta: +8 lines. The new no-effect classification lives with the existing settlement owner, preserving the admission module limit and its empty-cleanup contract.

Evidence

  • 82 tests passed across four focused files on Blacksmith Testbox, Node 24.22.1, verified source 9cbeeff4922ad1c9461dd27dadbb0e8925ad50e7. This covers the real broker refusal, prepared plugin-state readers, native receipt precedence, finish/error ordering, and cron/upstream readers. Testbox run.
  • Negative control: disabling only the new no-entry classification makes the broker regression fail at the retained reader with Native binding committed state is unavailable. The reviewed source bytes were restored. This is a mutation check, not a full parent-revision replay.
  • Formatting, whitespace, signed-commit hooks and line-cap checks pass. Independent P0–P2 autoreview found no actionable findings; an independent follow-up verified the behavior-preserving helper extraction.
  • Focused test groups took 15.82s and 13.30s wall time; the complete Testbox wrapper run, including preparation, took 227.9s. The 142-line allocation covers these regression assertions using existing fixtures; the shared test-line baseline is unchanged.
  • Exact-head CI passed: 52 successful jobs, 26 skipped, zero failures, including all three PostgreSQL conformance shards. Live Telegram/Desktop and production recovery are not established by this PR; attribution of any particular production incident remains unproven.

Preserve the broker-certified no-entry outcome through admission finish observers without overriding native receipts. Keep cron and session-upstream publication on the canonical observer path.

Add 142 regression-test lines for pre-dispatch refusal, native receipt precedence, and real publication consumers. Formatting and independent P0-P2 static review pass; execution proof is pending hosted CI because the approved remote launcher rejects a stale dependency donor.
@vincentkoc vincentkoc self-assigned this Nov 1, 2026
@clawsweeper

clawsweeper Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

ClawSweeper review in progress

ClawSweeper is reviewing this revision. This supersedes any previous blocked status.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added gateway Gateway runtime size: M labels Nov 1, 2026
@vincentkoc
vincentkoc marked this pull request as ready for review November 1, 2026 12:35
@vincentkoc
vincentkoc enabled auto-merge (squash) November 1, 2026 12:53
@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 1, 2026
@vincentkoc
vincentkoc merged commit f79a4e6 into main Nov 1, 2026
220 checks passed
@vincentkoc
vincentkoc deleted the fix/plugin-state-unstarted-publication-20261101 branch November 1, 2026 12:59
@vincentkoc

Copy link
Copy Markdown
Member Author

Merged via squash auto-merge.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 2, 2026
…0320)

Preserve the broker-certified no-entry outcome through admission finish observers without overriding native receipts. Keep cron and session-upstream publication on the canonical observer path.

Add 142 regression-test lines for pre-dispatch refusal, native receipt precedence, and real publication consumers. Formatting and independent P0-P2 static review pass; execution proof is pending hosted CI because the approved remote launcher rejects a stale dependency donor.
maplel pushed a commit to maplel/openclaw that referenced this pull request Nov 24, 2026
…0320)

Backport the bounded runtime fix for LOCAL11.8; preserve unrelated baseline behavior.

Release adaptation: retain release owner layout and omit unrelated source refactoring. Focused regression and touched-file checks recorded in the private lane manifest.

(cherry picked from commit f79a4e6)

Co-authored-by: RomneyDa <[email protected]>
(cherry picked from commit b7b1e13f74eb34b4aac28fd0ba952d427eb48ae2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. gateway Gateway runtime size: M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant