Skip to content

fix(control-ui): preserve session resume and fresh admin authority after reconnect - #182847

Closed
lucafucci wants to merge 18 commits into
openclaw:mainfrom
lucafucci:fix/control-ui-fresh-admin-input
Closed

lucafucci wants to merge 18 commits into
openclaw:mainfrom
lucafucci:fix/control-ui-fresh-admin-input

Conversation

@lucafucci

@lucafucci lucafucci commented Oct 24, 2026 •

Copy link
Copy Markdown

Related: #167867.

What Problem This Solves

Fresh administrator messages after a browser reconnect can be classified as recovered input, hiding automations from other conversations. Dropping the reconnect marker loses session-resume behavior, and an online follow-up in Queue mode can lose its fresh-submission ownership before delivery.

User Impact

Fresh browser submissions preserve conversation continuity and normal administrator automation management. Recovered and retried input retains its restrictions. Native embedded clients keep the existing boolean reconnect envelope.

Why This Change Was Made

The existing outbox retains freshness only within the originating document and authenticated connection. Durable recovery never serializes that ownership; explicit Retry clears it before admission. Gateway normalization separates session resume from recovered-input classification while retaining final-effect authority checks.

Only an authenticated openclaw-control-ui client in ui or webchat mode sends the fresh string envelope. The sender uses the actual authenticated connection-plan identity. macOS, Linux, iOS and Android embedded clients retain boolean true, preserving #171528 without extending native administrator authority.

Evidence

Head e348b870e04ca48f214d1c6ff015c8dbf0608965 integrates main 0dad367a93cb5669baf8ceda88d7f2c67353cc0f. Full focused verification succeeds on this head, without reusing previous results:

  • 14 ownership tests, 241 UI tests, 7 layout tests, 54 Gateway tests and 50 upstream E2E tests.
  • Real browser/Gateway reconnect, online/offline Queue, reload and Retry scenario.
  • Eight checks against a separate compiled Gateway: administrator read/update, write-only denials and revocation before effects.
  • Build, focused types, lint, formatting, base-red regressions and both size ratchets.

Evidence artifact, SHA256 4d7bb44d4056af3f970fe040e357b6105ce7bf89fc3ecd65381a6ef248a6f7d1.

The native regression crosses the real connection plan, shared request builder, Gateway normalizer and strict validator. All four native identities fail before the correction; browser and native cases pass afterward. Native coverage is not a physical application test. Runtime inference and job content are synthetic; authentication, admission, tools and persistence use production paths.

Independent static P0-P3 reviews of the correction and subsequent lint simplification found no actionable defects or remaining material context gaps. The final merge only combines E2E inventories, preserving both upstream and PR scenarios.

General CI and remaining decision

The focused result does not mean all general CI is green. General CI tests synthetic merge a6edbf2109ae92b1cd7a8fd936f87778322c96f0 against main 24fa8e716fc4d8b655a21d8edd063c50f04efcfb.

Matched replays on those exact revisions cover all nine reported failing cases: initial six and remaining three. Every selected case executed on each side, with no incomplete or setup-failure result.

Original failure Base Candidate
History offset across a silent gap Same assertion fails Same assertion fails
History page around an anchor Same assertion fails Same assertion fails
Private-server inventory Same missing child-failures entry Same missing child-failures entry
Catalog inventory admission Same timeout Same timeout
Session attention after chat error Same timeout Same timeout
Agent Tools loading skeleton Same timeout Same timeout
Context breakdown, 1440 px Same timeout Same timeout
Context breakdown, 390 px Same timeout Same timeout
Copy markdown Pass Pass

Eight failures reproduce directly on the upstream base. The copy-markdown timeout remains unreproduced, not fixed. These focused replays exclude other files and original shard ordering/concurrency; they do not establish a fully green general suite.

Initial comparison: base artifact, SHA256 272125923598edc91d00458cacda1721f72b29a1559c3528fb22240c03a4d432; candidate artifact, SHA256 53498b1259d1b78dbafad106e5a851921ed8ac45ba7194590102c2a8dac7f4c9.

Supplemental comparison: base artifact, SHA256 fe3a435c49494efc1e26ad7bbddc8e625e5c165d82ca408f2785b59cd4058fe9; candidate artifact, SHA256 d606aec3bac4a10a8c4059803f2cc481e7a51aa540cc22e26e71bf264788f1cb.

Maintainer acceptance of the bounded fresh-versus-recovered administrator-authority policy remains required. Automated reviews and passing tests do not constitute that acceptance.

@clawsweeper

clawsweeper Bot commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 24, 2026
@clawsweeper

clawsweeper Bot commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: stale review; fresh review needed.

Summary
The latest durable ClawSweeper review was for head ae491d9800e94a86ba895a201e01874568747222, but the PR head is now e348b870e04ca48f214d1c6ff015c8dbf0608965. Its old verdict and PR readiness labels are no longer current.

Next step
Comment @clawsweeper re-review when the current head is ready; pushes after the first review are not reviewed automatically.

Review history (6 earlier review cycles)
  • reviewed 2026-10-24T20:19:47.357Z sha a3eb360 :: needs real behavior proof before merge. :: [P2] Keep the submission owner within the enforced line limit
  • reviewed 2026-10-24T21:28:32.440Z sha 16dc493 :: needs real behavior proof before merge. :: [P2] Update the E2E ownership contract for the registered scenario
  • reviewed 2026-10-25T15:48:32.112Z sha 7f2acdb :: needs real behavior proof before merge. :: none
  • reviewed 2026-10-27T21:43:17.294Z sha a9d721d :: blocked before merge. :: [P1] Preserve session resume when classifying fresh reconnect input
  • reviewed 2026-10-28T00:01:54.556Z sha 436ef3e :: blocked before merge. :: [P2] Preserve fresh ownership while an online follow-up waits in Queue mode
  • reviewed 2026-10-29T16:55:12.524Z sha ae491d9 :: blocked before merge. :: [P1] Preserve the boolean reconnect marker for native embedded clients

Copy link
Copy Markdown
Author

@clawsweeper re-review

Updated head: 16dc493f860d18169e0ff4e1a817b447cd3c2e46.

Removed the max-lines suppression by moving the existing route/settings wait beside its underlying owner. The pinned browser CI job passes the ratchet, formatting, 176 focused UI tests, runtime build, and the new real-browser/Gateway regression: fresh admin input after reconnect sees a foreign-session automation; offline queued input does not.

The PR body now distinguishes this current-head proof from the older installed-baseline evidence and explicitly records the remaining end-to-end negative-coverage limits. Product/security-owner agreement on fresh-input classification is still needed; this does not claim maintainer approval.

@clawsweeper

clawsweeper Bot commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 24, 2026
@clawsweeper clawsweeper Bot removed clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 28, 2026

Copy link
Copy Markdown
Author

@clawsweeper re-review

Current head: ae491d9800e94a86ba895a201e01874568747222.

Addressed the online Queue callback finding. Freshness stays with the original document/connection and is cleared before explicit retry, including pre-transport failures. Durable rows never serialize the callback.

Current verification succeeds: 219 focused UI tests, the Queue regression red on the previous PR with five passing negative controls, and the real browser/Gateway reconnect, online Queue, offline Queue, reload and Retry flow. Build, format/lint, ownership and both size checks pass.

The workflow verifies that production and sibling test files are identical to candidate 29377c732fbe8e8ff7624594e3328e7a955c021a before reusing its successful 54 Gateway, 50 upstream browser and eight compiled-runtime authority/revocation checks. Only the two repaired fixtures differ. The body explains those earlier fixture failures and the exact evidence reuse.

The required body sections and the test argument error are corrected. Product/security-owner acceptance and broad upstream CI remain outstanding. No upstream merge or live deployment is claimed.

@clawsweeper

clawsweeper Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@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. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 message-delivery 🚨 May drop, duplicate, misroute, suppress, or wrongly target messages. and removed 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 Oct 29, 2026
@clawsweeper clawsweeper Bot removed proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 message-delivery 🚨 May drop, duplicate, misroute, suppress, or wrongly target messages. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. labels Oct 31, 2026
@openclaw-barnacle

Copy link
Copy Markdown

This pull request has been automatically marked as stale after 7 days without qualifying human activity.
Without new human activity, Barnacle may close it as not planned 7 days after this message was posted. This is administrative inactivity cleanup, not a claim that the problem is fixed.
A human update restarts the inactivity clock; a new PR head also restarts it. A maintainer can add no-stale for a durable hold, or bad-barnacle to suppress Barnacle. Remove the hold when work can resume.

@openclaw-barnacle

Copy link
Copy Markdown

Closing due to inactivity.
If you believe this PR should be revived, post in #clawtributors on Discord to talk to a maintainer.
That channel is the escape hatch for high-quality PRs that get auto-closed.

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 gateway Gateway runtime P2 Normal backlog priority with limited blast radius. size: L stale Marked as stale due to inactivity

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant