T12: OpenClaw Lane B sweep hermetic smoke (quiesce + dedupe) - #571
Merged
philcunliffe merged 1 commit intoAug 2, 2026
Merged
Conversation
New backfill_openclaw_fixture.js under hypaware-core/smoke/flows, mirroring backfill_claude_fixture.js / backfill_codex_fixture.js: writes a minimal OpenClaw v3 session JSONL in the nested-message-envelope shape (PR #552's reader) under a temp agents/<id>/sessions/ tree with a controllable mtime, drives the real createBackfillSweepDriver (T9) through a cron-due tick, and asserts (a) a file inside the default 180000ms quiesce window is skipped, (b) a file backdated past it is captured with native message identity, and (c) rerunning the sweep on a later cron-due tick (forcing a fresh devRunId, so the ai-gateway materializer's dedupe genuinely re-scans committed partitions) nets zero new rows for the already-written part_ids. Driving a real, non-dry-run sweep write for the first time (T9's own tests only ever exercised a mocked runBackfill seam) surfaced a latent bug: writeRows/flushDataset read ctx.query, which BackfillRunnerContext never carried and the daemon's createBackfillSweepDriver(...) call never supplied, so any real sweep write actually crashed on "Cannot read properties of undefined (reading 'getDataset')" in both the smoke and the real daemon path. Threaded query through BackfillRunnerContext, BackfillSweepDriverOptions, createBackfillSweepDriver, and the daemon's sweepDriver construction, and updated LLP 0172's field enumeration and ctx samples (Sections 4.3/4.4) to match. Extended the existing T9 unit tests (test/core/daemon-backfill-sweep.test.js) to cover the new required field and its passthrough. Task-Id: T12
philcunliffe
merged commit Aug 2, 2026
0c62a21
into
integration/openclaw-two-lane-capture
7 of 9 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
backfill_openclaw_fixturehermetic smoke underhypaware-core/smoke/flows, mirroringbackfill_claude_fixture.js/backfill_codex_fixture.js: writes a minimal OpenClaw v3 session JSONL in the nested-message-envelope shape (PR OpenClaw backfill reads message fields one level too high, projecting 0 rows #552's reader) under a tempagents/<id>/sessions/tree with a controllable mtime.createBackfillSweepDriver(T9) through a cron-due tick and asserts:devRunId, forcing a genuine re-scan of committed partitions) nets zero new rows for the already-writtenpart_idsrunBackfillseam):writeRows/flushDatasetreadctx.query, whichBackfillRunnerContextnever carried and the daemon'screateBackfillSweepDriver(...)call never supplied, so any real sweep write crashed onCannot read properties of undefined (reading 'getDataset'), in both the smoke and the real daemon path. ThreadedquerythroughBackfillRunnerContext,BackfillSweepDriverOptions,createBackfillSweepDriver, and the daemon'ssweepDriverconstruction.Test plan
npm run typecheckcleannpm test(3276 passed, 1 skipped, 0 failed)npm run smoke -- backfill_openclaw_fixtureoknpm run smoke -- backfill_claude_fixtureok (no regression)npm run smoke -- backfill_codex_fixtureok (no regression)npm run smoke -- daemon_foreground_start_stopok (real daemon sweep-driver wiring)npm run smoke -- walkthrough_backfill_client_historyok (CLI/onboarding backfill path)Task-Id: T12