Skip to content

chore: align concurrent session conflict expectations - #184667

Merged
shakkernerd merged 1 commit into
mainfrom
session-cas-phase-expectations-452
Oct 26, 2026
Merged

shakkernerd merged 1 commit into
mainfrom
session-cas-phase-expectations-452

Conversation

@shakkernerd

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes two concurrent-session regression tests that still expected later recovery errors after the canonical session-entry compare-and-swap began correctly rejecting genuine row changes earlier.

User Impact

There is no user-visible product change. The affected tests continue protecting worker admission, worktree cleanup, and stale CLI fork recovery while checking the error phase the current storage owner actually reaches.

Why This Change Was Made

The worker runtime case changes the required session row after worktree preparation, so the session-entry patch compare-and-swap rejects it before the later worker-admission guard. The caller-change control mutates a different admitted row and still reaches that later guard.

The CLI process case similarly performs a concurrent durable rebind before the stale turn commits. It now receives the canonical session-entry patch conflict before successor persistence can construct its later aggregate error. The nonzero process exit, newer durable binding, exact stale-fork arguments, no-dispatch behavior, absent persisted worktree fields, and cleanup assertions are unchanged.

Evidence

The original CI failures reproduced the earlier canonical conflict in both cases on source whose relevant test and producer blobs are identical to this change's base.

On the exact candidate:

  • Changed-file formatting and lint passed with zero warnings or errors.
  • The core-test-gateway-server and core-test-config-cli type graphs passed.
  • The complete gateway test file passed 17/17 cases, including the unchanged, caller-change, and runtime-change rows.
  • The complete CLI process test passed its real-child stale-fork scenario, preserving the nonzero exit, newer durable binding, and exact fork arguments.

PR CI and hosted review remain pending after publication.

@clawsweeper

clawsweeper Bot commented Oct 26, 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 gateway Gateway runtime cli CLI command changes size: XS labels Oct 26, 2026
@shakkernerd shakkernerd self-assigned this Oct 26, 2026
@shakkernerd
shakkernerd merged commit 486342b into main Oct 26, 2026
104 of 105 checks passed
@shakkernerd
shakkernerd deleted the session-cas-phase-expectations-452 branch October 26, 2026 13:25
@shakkernerd

Copy link
Copy Markdown
Contributor Author

Fixed: Concurrent session regression coverage now checks the canonical rejection phase while preserving worker admission and stale CLI fork protections.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 27, 2026
Align concurrent session conflict regression coverage with the canonical earlier rejection while preserving worker admission and stale CLI fork protections.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli CLI command changes gateway Gateway runtime size: XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant