Skip to content

fix(ui): preserve offline drafts and resume canceled queue edits - #133628

Merged
steipete merged 2 commits into
mainfrom
refactor/ui-outbox-ownership-cleanup
Aug 31, 2026
Merged

steipete merged 2 commits into
mainfrom
refactor/ui-outbox-ownership-cleanup

Conversation

@steipete

@steipete steipete commented Aug 30, 2026 •

Copy link
Copy Markdown
Contributor

Closes #133555 — offline split-pane drafts can remain only in tab storage after queue activity.
Closes #133603 — Cancel can close a queued edit after reconnect without waking delivery.

Related: #133067 — the earlier main-session recovery-target repair; #133409 — the already-landed custody simplification. Their changes are not duplicated here.

Additional instructions

Maintainer-owned branch in openclaw/openclaw; maintainers can update it.

What Problem This Solves

Fixes an issue where users composing an independent draft while manipulating an offline split-pane queue could see newer text in the UI and tab storage while the native durable draft remained older. It also fixes Cancel closing a queued-message editor after reconnect without waking delivery: the original messages stayed parked until another event occurred.

This maintainer-requested follow-up removes repeated queue discovery, overlapping admission arguments, duplicate draft bookkeeping and thin adapters. Real-browser verification also exposed two nearby ownership mistakes: saved selection could override an explicit /chat/main URL, and first use of attachment icons during a complete Gateway outage could leave a rejected stylesheet import cached.

Why This Change Was Made

The existing owners now carry their facts forward. One located queue row includes its captured destination; callers supply the admission captured before asynchronous work; committed and attempted draft revisions remain separate facts inside one record; New Session lineage retains in-flight writes without parallel maps. Composer persistence reserves its pending snapshot before synchronous publication can reenter it, and offline reconciliation uses the already-authenticated retained owner.

Cancel wakes the existing drain only after successfully releasing its local edit hold. It does not mutate storage, invent a retry or bypass history, uncertainty, credential or peer-edit checks. Explicit startup routes and attachment styles remain with their actual owners, while the sidebar asks the projection for domain answers rather than interpreting storage keys and raw maps.

Storage boundary: the consolidated maps are in-memory bookkeeping, not a serialized-format migration. Metadata v4, IndexedDB v2, storage keys and limits, retention, migration receipts/source retention, tombstones, revision/CAS and winner semantics, uncertainty, and Blob custody remain unchanged. No new dependency, configuration option, schema, compatibility layer, timeout increase or performance-budget change.

User Impact

Independent drafts remain durably committed through offline queue activity. Cancel resumes original queued messages in order, preserving their original run IDs and attachment bytes, without submitting or overwriting the main composer draft. Explicit agent URLs win over saved selection, and attachment icons work on first offline use.

The cleanup removes 114 production lines: +509/−623. Tests/support are +1,079/−422, net +657, across 80 files overall. Upstream #133409's 139 removed production lines are excluded. The structural reduction includes one queue-location policy, consolidated revision/lineage containers, explicit admission capture, and removal of forwarding layers, obsolete scope reexports, promise-return wrappers and raw-map sidebar coupling.

Evidence

Resolved-head proof and final Cancel/Save recordings document the rebuilt production candidate. The later CI correction is test-only; production bytes are unchanged.

The native draft regression failed before repair at transaction-complete IndexedDB equality. The extended same-tab Cancel regression also failed before the action fix: the editor closed, but only the seed send existed. The identical test then passed with the existing drain wake, preserving original run IDs, attachment bytes, FIFO, the peer edit hold and the independent visible/durable draft.

The first current-main integration passed 1,492 cases in 43 files, full changed checks, both compiler contracts and both cycle checks. The subsequent small refresh passed 602 focused cases in 12 files, both compilers and scoped lint. Fresh complete builds and independent scoped Codex reviews passed; the final build measured 345,427/347,353 B startup JavaScript gzip and 54,771/54,784 B largest CSS gzip, with unchanged limits and no ineffective-dynamic-import warnings. Frozen source hashes were matched to the resulting commit and served assets. These overlapping validation cohorts are not summed as unique tests.

Real isolated flow: Gateway → OpenClaw runtime → OpenAI (gpt-5.6-luna), with synthetic content and no fabricated Gateway replies. The final rebuilt Cancel and Save runs each completed three logical sends, exact 91-byte attachment delivery, correct original/replacement run identities and FIFO, and independent native/visible draft retention. Both had zero browser errors or observer failures and complete owned-resource cleanup. Earlier source-equivalent flows also passed whole-Gateway restart/first-offline attachment, both main/work destination directions, attachment reload, legacy confirmation/explicit uncertainty Retry, newer New Session handoff and Incognito. Every offered capture was inspected; published downloads matched the inspected originals.

CI correction: the first exact-head run and the requested retry exposed a page-wide locator matching both the active pane and a retained hidden pane. Local diagnostics showed one visible reply, one canonical reply per pane and one send—not duplicate delivery. The test now scopes strict assertions to the active owner, adds canonical/DOM uniqueness and recovery-history ownership checks, and keeps fixture agent identity independent of activity. The original 26-file selection plus fitting siblings pass 306 cases in 30 files, with no skips/todos; the exact final case, compilers, lint and independent review also pass. Local replay order differs from CI cache order, but the defect reproduces in isolation. Fresh exact-head CI and complete browser audit passed: 334 files / 1,365 tests across 13 disjoint mocked shards, with zero failed/skipped/retried cases; separate real-Gateway 4 files / 9 cases and browser-extension 1 file / 1 case also passed. The supplemental UI suite has one opt-in memory Chromium skip, not counted as executed proof.

Explicit gaps: raw global live verification failed at the seed turn, before queue activity, because a backend ACP metadata lookup dropped the explicit agent owner. Custom-main variants were blocked by the existing loaded-config policy forcing main despite the documented custom key. These are separately recorded follow-ups, not hidden by special fixtures or counted as live passes. The distinct recorded-idle wake-up work in #131948 is not incorporated.

Provenance: exact introducing commits and last-known-good releases are not established. The pre-fix Cancel action's complete owning module matched the verified current-main snapshot 5835fbeac7d6be65612fb666f47f10b6bc4ca30c. No introduction claim is inferred from blame alone.

Validation limitation: the broader CI-file replay regenerated ten older quota/lobster fixture PNGs at fixed paths before backup; their prior bytes were not preserved. Eight other fixture outputs were restored. All 79 task-specific outbox captures remained byte-identical, and none of the overwritten fixture outputs is offered as PR proof. Run-scoped fixture capture output is recorded as a separate follow-up.

Before and after

Before: Cancel closed the editor, but both messages remained parked.

Before: closed edit and parked queue

After: both original messages delivered, with the independent draft retained.

After: original delivery and retained draft

Final uncut Cancel flow:

attachment-3367646139.webm

Final uncut Save control:

attachment-2500158143.webm

@clawsweeper

clawsweeper Bot commented Aug 30, 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 app: web-ui App: web-ui size: XL maintainer Maintainer-authored PR labels Aug 30, 2026
@clawsweeper clawsweeper Bot added merge-risk: 🚨 message-delivery 🚨 May drop, duplicate, misroute, suppress, or wrongly target messages. merge-risk: 🚨 session-state 🚨 May lose, corrupt, stale, or mis-associate session, agent, or context state. P1 High-priority user-facing bug, regression, or broken workflow. proof: 🎥 video Contributor real behavior proof includes video or recording evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 30, 2026
@clawsweeper

clawsweeper Bot commented Aug 30, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 30, 2026, 11:17 PM ET / August 31, 2026, 03:17 UTC.

ClawSweeper review

What this changes

The branch preserves durable offline composer drafts, resumes queued delivery after canceling a reconnect-time edit, and consolidates Control UI outbox ownership and related regression coverage.

Regression provenance

Possible regression — probable (reproduction; reviewed change). No predecessor PR is attributed.

Merge readiness

⚠️ Ready for maintainer review - 3 items remain

This maintainer-owned PR remains necessary: current main lacks both the reconnect-time Cancel wake and the pending-before-notify draft fence. The repair follows the existing outbox owner boundary and has focused browser coverage, but current main has advanced substantially through the same files since the branch diverged.

Priority: P1
Reviewed head: 789afd1c42cdbb7b21abd960c496d7bc043df2df

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) Strong focused behavior evidence and a coherent net-negative repair are tempered by substantial same-surface current-main drift.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (recording): The captured PR body and follow-up comment tie before/after recordings to the Control UI’s durable-draft and Cancel queue owners, reporting an isolated Gateway-to-runtime flow with observed FIFO sends, preserved original identifiers and attachment bytes, and retained draft state.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (recording): The captured PR body and follow-up comment tie before/after recordings to the Control UI’s durable-draft and Cancel queue owners, reporting an isolated Gateway-to-runtime flow with observed FIFO sends, preserved original identifiers and attachment bytes, and retained draft state.
Evidence reviewed 5 items Introduced Cancel wake: The branch invokes the established durable-outbox resume path only after the local queued-edit hold was successfully released.
Drain owner and delivery fences: The resume path requires a connected client, refreshes the ownership projection, and schedules scope-specific drains; the drain continues to honor queued-edit holds before sending.
Behavioral regression coverage: The added browser regression exercises offline split panes, queue removal and reordering, reconnect plus Cancel, FIFO delivery, original run IDs, attachment bytes, and durable independent-draft retention.
Findings None None.
Security None None.

How this fits together

The Control UI keeps unsent drafts and queued chat messages in browser storage while the Gateway connection changes. Captured conversation identity determines which durable draft and queue are restored, displayed, and eventually sent through the Gateway.

flowchart LR
  A[Control UI split panes] --> B[Browser draft and outbox storage]
  B --> C[Captured conversation identity]
  C --> D[Reconnect and queue drain]
  D --> E[Gateway chat delivery]
  C --> F[Durable composer draft]
  F --> A
Loading

Before merge

  • Resolve merge risk (P1) - Current main is 54 commits ahead of the shared base and has changed the draft, queue, drain, and Cancel owners; the supplied test merge is stale, so the final merged behavior has not been proven.
  • Resolve merge risk (P1) - This change governs durable draft state and queued-message delivery, so the rebase needs fresh owner and browser-shard evidence before merge.
  • Complete next step (P2) - This protected maintainer-owned PR needs a current-main rebase and exact-head verification, not an automated repair branch.
Agent review details

Security

None.

PR surface

Source -142, Tests +685. Total +543 across 80 files.

View PR surface stats
Area Files Added Removed Net
Source 32 515 657 -142
Tests 48 1073 388 +685
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 80 1588 1045 +543

Review metrics

Metric Value Why it matters
Production versus test delta production -114; tests/support +657 The bug repair reduces production code while adding behavioral coverage for durable drafts and queued delivery.

Stored data model

Persistent data-model change detected: serialized state: ui/src/pages/new-session/draft-persistence.ts, serialized state: ui/src/pages/new-session/rejected-initial-turn.ts, unknown-data-model-change: ui/src/pages/new-session/draft-persistence.ts. Confirm migration or upgrade compatibility proof before merge.

Merge-risk options

Maintainer options:

  1. Rebase and re-verify the merged candidate (recommended)
    Rebase onto current main, resolve the overlapping outbox-owner changes, then run the focused browser regressions and required exact-head CI before merge.

Technical review

Best possible solution:

Rebase the coherent owner-boundary repair onto current main, retain its split-pane durable-draft and Cancel/FIFO regression coverage, and verify the exact merged candidate before landing.

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

Yes, source-reproducible: the added browser regression drives the reported split-pane/offline/reconnect sequence and verifies the durable draft plus post-Cancel delivery outcome. This review did not execute the checkout.

Is this the best way to solve the issue?

Yes: keeping conversation identity captured at admission, retaining the authenticated browser owner while offline, and waking the existing drain after a released edit hold repairs the responsible UI owners without adding policy or storage formats.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against bef84be7f5e9.

Labels

Label justifications:

  • P1: A reconnect-time Cancel can leave valid queued messages without delivery until another event occurs.
  • merge-risk: 🚨 session-state: The branch changes durable composer-draft ownership and revision/reconciliation behavior across offline state changes.
  • merge-risk: 🚨 message-delivery: The branch changes the queue drain wake and captured destination handling for queued chat messages.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (recording): The captured PR body and follow-up comment tie before/after recordings to the Control UI’s durable-draft and Cancel queue owners, reporting an isolated Gateway-to-runtime flow with observed FIFO sends, preserved original identifiers and attachment bytes, and retained draft state.
  • proof: sufficient: Contributor real behavior proof is sufficient. The captured PR body and follow-up comment tie before/after recordings to the Control UI’s durable-draft and Cancel queue owners, reporting an isolated Gateway-to-runtime flow with observed FIFO sends, preserved original identifiers and attachment bytes, and retained draft state.
  • proof: 🎥 video: Contributor real behavior proof includes video or recording evidence. The captured PR body and follow-up comment tie before/after recordings to the Control UI’s durable-draft and Cancel queue owners, reporting an isolated Gateway-to-runtime flow with observed FIFO sends, preserved original identifiers and attachment bytes, and retained draft state.

Evidence

What I checked:

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rank-up moves

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

  • Rebase onto current main and publish fresh exact-head Control UI browser-shard and owner-test results for the resolved merge candidate.

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 (4 earlier review cycles)
  • reviewed 2026-08-30T23:58:23.670Z sha 514049bb1c176a68fd2b7f10151d4c0bc01595e8 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-31T01:05:41.461Z sha b27752962479f27b94ae32a95205aa0009164bb0 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-31T01:44:32.393Z sha 1038fb3 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-31T03:08:29.396Z sha 789afd1 :: needs maintainer review before merge. :: none

Unify queue location and captured admission ownership, consolidate draft
revision/lineage bookkeeping, and remove obsolete projection adapters.
Reserve composer snapshots before synchronous publication and reconcile
native persistence using the retained authenticated offline owner.

Wake the existing drain after successful queued-edit Cancel without
mutating the stored row. Preserve explicit startup routes and own file-icon
styles statically so their first offline use cannot cache a rejected load.

Fixes #133555
Fixes #133603

Validated owner and native-browser regressions, integration checks,
compilers, complete builds, scoped independent review, and real isolated
Gateway/provider/browser flows including Cancel and Save. Production code
shrinks; persistence formats, CAS, uncertainty and Blob custody stay unchanged.
@steipete
steipete force-pushed the refactor/ui-outbox-ownership-cleanup branch from b277529 to 1038fb3 Compare August 31, 2026 01:37
@steipete
steipete marked this pull request as ready for review August 31, 2026 01:38
@steipete

steipete commented Aug 31, 2026 •

Copy link
Copy Markdown
Contributor Author

Resolved-head proof for 1038fb3cd98b, addressing the conflict-resolution and exact-candidate replay requested in the latest ClawSweeper review.

Both required integrations preserve newer main behavior. The first kept pending-input/consumption receipts, active-run state, preference fencing and attachment release ownership; it required two test-only migrations to the canonical admission and fixture APIs. The later conflict was only the Copy submenu test import: the new menu interaction stays, and the removed fixture wrapper stays removed. No compatibility API or production workaround was restored.

The first integrated tree passed 1,492 cases in 43 files, full changed checks, both compiler contracts and both cycle checks. The final small refresh passed 602 focused cases in 12 files (including native queue/draft/attachment, current menus and visibility/history coverage), both compiler contracts and scoped lint, with zero failures, skips or todos. Those cohorts overlap and are not summed as unique tests. Earlier stale-caller failures and the one no-output watchdog termination remain recorded; the final selected runs pass without larger timeouts or weakened assertions.

The fresh complete env OPENCLAW_BUILD_CACHE=0 pnpm build passed. Startup JS is 345,427 / 347,353 B gzip and largest CSS 54,771 / 54,784 B gzip, using main's existing limits without changes. The build ran on the frozen paused-rebase candidate; its complete patch SHA-256 1c048641bed5a26a09a97473ef7681c822ca8cfedc032368c353c2f6dfa5131c and all 79 changed-file hashes were verified against the resulting commit. The build's metadata names its base, 923454e6ddb1, but this is combined-candidate proof, not a build of the unmodified base. Fresh independent Codex review of that complete candidate returned scoped-clean at the configured blocking-priority threshold, with no findings.

Rebuilt real flow: actual isolated Gateway → OpenClaw runtime → OpenAI (gpt-5.6-luna), no fabricated Gateway replies. Both Cancel and Save completed three logical sends each (seed plus the two queued turns), with zero browser errors or observer failures. Cancel delivered the original run identities and exact 91-byte attachment in FIFO order; Save delivered the new replacement run followed by the original tail. Peer removal stayed blocked during the edit, and the independent composer draft remained visible and committed in native storage. All owned browser/Gateway processes and disposable state were cleaned. Both served assets/index-CuS0C49v.js, SHA-256 34b85a1267ee316f04b917543c3945b0662b1fe127902bfcd72d9a5cfc15e05a.

The attached final screenshot and uncut Cancel/Save recordings were inspected: synthetic conversations/files, empty or masked credential controls, and no unrelated/private data. The earlier failed-Cancel screenshot remains in the PR body as the before evidence.

Stored-data review note: the consolidated revision/lineage maps are in-memory bookkeeping. Metadata v4, IndexedDB v2, keys, retention, migration receipts/source retention, tombstones, CAS/winner semantics, uncertainty and Blob custody remain unchanged. Existing legacy migration, conflict, credential and native-storage cases remain covered; this is not a schema or serialized-format migration.

The separately recorded raw-global ACP ownership and custom-main policy gaps remain explicit; no global/custom-main live pass is claimed. Final exact-head CI and complete browser inventory are recorded below.

Final resolved candidate: original Cancel delivery and retained independent draft

attachment-3367646139.webm
attachment-2500158143.webm

Final exact-head verification and review disposition

The corrected head is 789afd1c42cd. CI run 33352526228, attempt 1 completed successfully. Actual checkout and workflow identity in every audited job is synthetic merge 6d48161b0759687f58e0824434ead28ea359df98, with parents 2f6a67102078993421c2382d3f4badc3208f762e and this exact PR head—not an assumed checkout of the head alone.

Canonical discovery and actual execution reconcile 334 mocked-browser files / 1,365 passed cases across 13 disjoint shards. All 78 pairwise file intersections are empty; no missing, unexpected or duplicate files. Every terminal count agrees with observed case records. Zero failed/skipped/todo/pending/retried/repeated cases, and zero reported unhandled errors or leaked processes in these shards. The complete job listing reconciles 127 unique jobs across two pages. Seven E2E bodies and timing weights differ between head and the tested merge; filenames and selection-config bytes agree. Actual shard membership and counts came from CI logs, not head timing weights or an inferred partition.

Mocked shard Job Files Passed
1 99368672079 25 105
2 99368671987 26 111
3 99368672055 25 99
4 99368672029 26 79
5 99368672020 25 94
6 99368672244 26 104
7 99368672008 26 92
8 99368672003 25 117
9 99368672103 26 136
10 99368672092 26 120
11 99368672301 26 123
12 99368672044 26 95
13 99368672257 26 90

Separately, real Gateway job 99368671395 passed all 4 files / 9 cases, and browser-extension job 99368672160 passed 1 file / 1 case. These are not added to the mocked union. Supplemental Control UI job 99368671641 reports 847 files, 13,040 passed and one skipped case: the explicitly opt-in memory-panel Chromium proof did not execute. The zero-skip claim applies to the audited E2E lanes, not all UI tests.

The earlier head's first run and the requested retry both failed at the page-wide assistant locator. The final test-only correction scopes the active rendered pane and strengthens single-send, DOM/canonical reply uniqueness and captured recovery-owner assertions. Fixture agent identity is now independent of busy/idle state. Local proof passed 306 cases in 30 files plus the exact final case, compilers/lint and a fresh independent scoped Codex review. Production at789 is byte-identical to the rebuilt/live-tested1038 candidate above; the recordings are not being relabeled as a different production build.

Latest ClawSweeper rank-up disposition: no actionable code/security findings remain. The requested resolved-candidate owner/native tests, real Cancel/Save replay and exact-head browser shards have been completed. I am deliberately skipping another rebase solely for main drift: comparing shared base 923454e6ddb1b054956d9f733215b749a92f625e to verified main d8d70cfbf04e648bd6329eb309f0d735f7043e21 shows only one intersecting PR file, ui/src/pages/chat/chat-send.test.ts, and no changes to this PR's 30 production files. Its upstream history-limit assertions and unused-toast argument removal combine cleanly; a conflict-free merge-tree preserves the exact added/removed upstream test lines. The sibling history constant and tooltip layout optimization were inspected. A PR-versus-main difference in an owner file is not itself upstream drift in that owner. Native conflict/head/CI guards remain required; no bypass or stale-CI substitution is used.

Exact focused local commands from the final production refresh (overlapping cohorts are not summed as unique tests):

node scripts/run-vitest.mjs run ui/src/pages/chat/chat-state.test.ts ui/src/pages/chat/chat-send.test.ts ui/src/pages/chat/composer-persistence.test.ts ui/src/lib/chat/outbox-store.test.ts ui/src/pages/chat/chat-history.inflight.test.ts --maxWorkers 2 --reporter=default --reporter=json --outputFile=.artifacts/outbox-cleanup/rebase2-unit.vitest.json
node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner --maxWorkers 2 ui/src/e2e/session-color.e2e.test.ts ui/src/e2e/session-management.copy-session-id.e2e.test.ts ui/src/e2e/session-management.sidebar.e2e.test.ts ui/src/e2e/session-management.draft-indicator.e2e.test.ts ui/src/e2e/composer-recovery-fences.e2e.test.ts ui/src/e2e/attachment-file-styles.e2e.test.ts ui/src/e2e/composer-draft-store.e2e.test.ts --reporter=default --reporter=json --outputFile=.artifacts/outbox-cleanup/rebase2-native.vitest.json
pnpm tsgo:ui
node scripts/run-tsgo-core-test-shards.mjs
node scripts/run-oxlint.mjs --tsconfig config/tsconfig/oxlint.core.json ui/src/e2e/session-management.copy-session-id.e2e.test.ts ui/src/pages/chat/chat-state-events.ts ui/src/e2e/session-color.e2e.test.ts ui/src/e2e/session-management.sidebar.e2e.test.ts
env OPENCLAW_BUILD_CACHE=0 pnpm build

Final LOC remains production +509/−623 = −114; tests/support +1,079/−422 = +657; 80 files. The separately recorded raw-global ACP and custom-main live gaps remain—not claimed passes. Ten older unrelated quota/lobster fixture PNGs were overwritten before backup during local replay; eight other outputs were restored, all79outbox captures and published proof remain intact. Run-scoped fixture output is a separate follow-up. Owned live resources are stopped and the temporary provider-key copy has been removed.

Native review artifacts validated, mandatory hosted-evidence preparation passed in exact-head mode, and native merge completed as 8715e87f666c. Both linked issues closed automatically. The landed production files match the reviewed head exactly; the worktree is clean and synchronized to main. The native drift warning was advisory under the existing policy, with the overlapping test changes inspected as described above. OPENCLAW_TESTBOX=1 verifies the existing hosted evidence; it does not mean a new Testbox lease was created. No release, package publication or version bump is requested.

Retained hidden panes can contain the same conversation output. Keep
strict visible-owner assertions and require one canonical reply and one
send instead of querying every cached pane in the page.

Keep fixture session and run identities tied to the agent, not its busy
flag, and verify that recovery history queries retain the Work owner.

Reproduced both page-wide locator failures before correction. The original
26-file selection and fitting siblings pass; timeouts, runtime behavior,
and deliberate raw-event fault injection remain unchanged.
@steipete
steipete merged commit 8715e87 into main Aug 31, 2026
162 checks passed
@steipete
steipete deleted the refactor/ui-outbox-ownership-cleanup branch August 31, 2026 03:46
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 31, 2026
…nclaw#133628)

* fix(ui): preserve offline drafts and resume canceled queue edits

Unify queue location and captured admission ownership, consolidate draft
revision/lineage bookkeeping, and remove obsolete projection adapters.
Reserve composer snapshots before synchronous publication and reconcile
native persistence using the retained authenticated offline owner.

Wake the existing drain after successful queued-edit Cancel without
mutating the stored row. Preserve explicit startup routes and own file-icon
styles statically so their first offline use cannot cache a rejected load.

Fixes openclaw#133555
Fixes openclaw#133603

Validated owner and native-browser regressions, integration checks,
compilers, complete builds, scoped independent review, and real isolated
Gateway/provider/browser flows including Cancel and Save. Production code
shrinks; persistence formats, CAS, uncertainty and Blob custody stay unchanged.

* test(ui): scope cross-agent outbox proof to the active pane

Retained hidden panes can contain the same conversation output. Keep
strict visible-owner assertions and require one canonical reply and one
send instead of querying every cached pane in the page.

Keep fixture session and run identities tied to the agent, not its busy
flag, and verify that recovery history queries retain the Work owner.

Reproduced both page-wide locator failures before correction. The original
26-file selection and fitting siblings pass; timeouts, runtime behavior,
and deliberate raw-event fault injection remain unchanged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui maintainer Maintainer-authored PR merge-risk: 🚨 message-delivery 🚨 May drop, duplicate, misroute, suppress, or wrongly target messages. merge-risk: 🚨 session-state 🚨 May lose, corrupt, stale, or mis-associate session, agent, or context state. P1 High-priority user-facing bug, regression, or broken workflow. proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 🎥 video Contributor real behavior proof includes video or recording evidence. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XL status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

1 participant