Skip to content

fix: restore session initialization query accounting - #184662

Merged
shakkernerd merged 1 commit into
mainfrom
actor-payload-query-classifier-448
Oct 26, 2026
Merged

shakkernerd merged 1 commit into
mainfrom
actor-payload-query-classifier-448

Conversation

@shakkernerd

Copy link
Copy Markdown
Contributor

What Problem This Solves

The session-actor initialization regression tracks the exact database work needed to publish the first transcript state. It expects one payload query returning the three initialization rows, alongside the existing write, receipt, rollback, watermark, and restart checks.

The production query now selects event_json, event_zstd, and event_utf8_bytes directly so compressed payloads can be decoded by the existing payload owner without copying expanded text through SQLite. The test's SQL classifier still recognizes only the former aliased decoded expression. As a result, the query runs correctly but the test records zero payload reads and fails its accounting assertion.

User Impact

This restores the reliability of the existing initialization regression. It does not change production SQL, transcript decoding, persisted data, configuration, database schema, runtime behavior, or public interfaces.

All existing behavioral assertions remain in place, including exactly one payload query returning three rows, the initialization receipt and persisted events, rollback of a refused append without a watermark, and state preservation across actor and database restart.

Why This Change Was Made

The classifier now identifies the canonical direct payload-column projection while retaining its existing guards for the sequence projection, transcript_events source, and selected sequence set. That keeps the observation specific to the one bounded payload read without loosening counts or matching unrelated transcript queries.

The correction stays in the test that owns this accounting contract. No new fixture, helper, test case, production instrumentation, or duplicate coverage is introduced.

Evidence

GitHub Actions run 40316438338, job 121550439503, provides the original failure: the test counted zero payload queries while every other reported query count matched. Source history identifies 13b0b3fb4678732d6eff8be7ae9bb601adc91a4b as the intentional query change, and both the failing test blob and canonical query-owner blob remained unchanged through the selected base.

The first exact remote attempt stopped at formatting before lint, types, or tests. The authorized exact-file formatter then produced the canonical one-line layout; that transition changed no query text or behavior. On the corrected frozen candidate, changed-file formatting and lint passed, the affected core-test-agents-sessions type graph passed, and both complete literal files passed all 19 tests with no skips. This includes the changed initialization regression and the unchanged owner control covering identity and compressed payload decoding.

The installed P0-P3 autoreview reported no findings on the semantically identical pre-format diff, with the explicit limitation that it did not independently receive the surrounding test or generated SQL. Calibrated independent review, hosted CI, and hosted review remain readiness obligations 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.

@shakkernerd shakkernerd self-assigned this Oct 26, 2026
@shakkernerd
shakkernerd merged commit c7011b3 into main Oct 26, 2026
98 of 99 checks passed
@shakkernerd
shakkernerd deleted the actor-payload-query-classifier-448 branch October 26, 2026 13:18
@shakkernerd

Copy link
Copy Markdown
Contributor Author

Fixed: session initialization query accounting now recognizes the canonical compressed-payload read while retaining existing state and rollback coverage.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 27, 2026
Session initialization regression coverage now recognizes the canonical compressed-payload read while retaining exact query counts and existing state, receipt, rollback, watermark, and restart assertions.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant