Skip to content

fix: make Back work within channel setup#108007

Merged
jesse-merhi merged 5 commits into
mainfrom
jesse/channel-setup-back-navigation
Jul 20, 2026
Merged

fix: make Back work within channel setup#108007
jesse-merhi merged 5 commits into
mainfrom
jesse/channel-setup-back-navigation

Conversation

@jesse-merhi

@jesse-merhi jesse-merhi commented Jul 15, 2026

Copy link
Copy Markdown
Member

Related: #100906

AI-assisted: yes

What Problem This Solves

Fixes an issue where terminal users setting up a channel could not revise an earlier answer or return from the selected channel's first prompt to the channel picker. Full onboarding and openclaw channels add reached the same shared channel coordinator through different navigation wrappers, so Back was unavailable or stopped at the wrong boundary.

Why This Change Was Made

Adds a typed, channel-scoped navigation outcome in the shared prompt navigator and lets the channel setup coordinator own prompt replay and rollback. Left-arrow Back revisits reversible prompts inside the selected channel; Back from that channel's first prompt returns to channel selection. Ctrl-C remains full wizard cancellation.

The scope closes before installs, key writes, authentication handshakes, and other declared persistent effects. Wizard-local config, selection/account bookkeeping, and post-write hooks are discarded when returning to the picker, while metadata for an already accepted external plugin install is retained so the installed package remains managed.

This PR is intentionally terminal-only. It does not add Control UI buttons or a Gateway navigation transport; those clients continue their existing behavior.

User Impact

Users running openclaw onboard or interactive openclaw channels add can use the terminal's left-arrow Back navigation within channel setup without restarting the entire wizard. Sensitive text answers are not cached for forward replay, and durable work is not repeated.

Terminal Proof

openclaw-channel-back-navigation-demo.mp4

What this shows: openclaw channels add enters ClickClack, Discord, and Google Chat setup, and left-arrow Back returns from each channel's first prompt to the shared channel picker. The run ends with Ctrl-C cancellation, so no configuration is saved.

State: Current PR head (6fd84fe7335), rebased onto main at 783a5d21cfc. The recording uses Node 22.23.1. Real loading pauses were trimmed; all shown wizard interactions are from this branch.

Evidence

  • fnm exec --using=22.23.1 node scripts/run-vitest.mjs src/wizard/navigation-prompter.test.ts src/flows/channel-setup.test.ts src/commands/channels.add.test.ts src/wizard/setup.test.ts extensions/reef/src/setup.test.ts — 94 tests passed across four Vitest shards after resolving the Reef rebase conflict against the newer identity-storage implementation.
  • Coverage includes prompt replay, first-prompt return to the picker, declarative and custom adapters, Ctrl-C propagation, attempt rollback, post-write-hook rollback, accepted-install metadata retention, full-onboarding scope reset, and the Reef key-write boundary.
  • Manual terminal proof above — ClickClack, Discord, and Google Chat each return to the shared picker with left-arrow; Ctrl-C cancels without saving.
  • ./node_modules/.bin/oxfmt --check on all nine changed files — passed.
  • git diff --check origin/main...HEAD — passed on the current head.
  • The final base-only rebase completed the 29-test unit shard locally; the next shard then stopped before running tests because the delegated dependency bootstrap left the local packages/net-policy workspace link for ipaddr.js unresolved. A clean-install retry reproduced that import failure before any test assertion. Fresh CI and ClawSweeper review remain the source of truth for the frozen current head.
  • The broader changed-surface check was attempted under supported Node 22.23.1, but its delegated Testbox lane stalled after dependency bootstrap without running a validation command; no code/test failure was reported by that lane.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation app: web-ui App: web-ui gateway Gateway runtime commands Command implementations channel: reef Channel integration: reef size: XL maintainer Maintainer-authored PR labels Jul 15, 2026
@jesse-merhi
jesse-merhi force-pushed the jesse/channel-setup-back-navigation branch from 25d85f7 to 0150562 Compare July 15, 2026 14:20
@openclaw-barnacle openclaw-barnacle Bot removed docs Improvements or additions to documentation app: web-ui App: web-ui gateway Gateway runtime labels Jul 15, 2026
@jesse-merhi
jesse-merhi force-pushed the jesse/channel-setup-back-navigation branch from 0150562 to 27b4d0e Compare July 15, 2026 14:43
@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 🎥 video Contributor real behavior proof includes video or recording evidence. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. labels Jul 16, 2026
@clawsweeper

clawsweeper Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 20, 2026, 12:28 AM ET / 04:28 UTC.

Summary
Adds scoped terminal Back navigation for interactive channel setup, returning from a channel’s first prompt to the picker and rolling back wizard-local state before persistent effects.

PR surface: Source +215, Tests +738. Total +953 across 9 files.

Reproducibility: no. high-confidence before-fix reproduction was established in this read-only review. The PR supplies focused tests and an after-fix terminal recording, but those do not independently demonstrate the prior current-main failure.

Review metrics: none identified.

Merge readiness
Overall: 🐚 platinum hermit
Proof: 🦞 diamond lobster ✨ media proof bonus
Patch quality: 🐚 platinum hermit
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • Obtain an explicit setup-area decision on accepted-install retention versus full rollback.
  • [P2] Let the required checks finish on the exact current head before merge.

Risk before merge

  • [P1] Merging changes the setup rollback boundary: accepted external-plugin install metadata can survive a return to the channel picker while wizard-local config, account bookkeeping, and post-write hooks are discarded. A setup-area owner should explicitly confirm that this shared adapter contract is the intended upgrade behavior.

Maintainer options:

  1. Confirm the persistence contract before merge (recommended)
    A setup-area owner should explicitly accept that accepted external install metadata survives scoped Back navigation while wizard-local state is rolled back.
  2. Pause for a narrower lifecycle design
    If installation metadata should not survive returning to the picker, pause this PR and define a narrower owner-level rollback contract.
Copy recommended automerge instruction
@clawsweeper automerge

Special instructions:
After owner confirmation, require the exact-head required checks to complete before merging.

Next step before merge

  • [P2] A setup-area owner must decide the intentional persistence and rollback semantics before this member-authored, maintainer-labeled PR can be landed.

Maintainer decision needed

  • Question: Should channel setup preserve accepted external-plugin installation metadata when Back returns to the picker, while discarding all wizard-local configuration and post-write-hook state?
  • Rationale: This is an intentional shared setup lifecycle contract, not a mechanical defect: it determines which effects survive navigation across bundled and external channel adapters.
  • Likely owner: jesse-merhi — The linked and current PRs place this contributor closest to the proposed shared setup contract; final product acceptance still requires a setup-area reviewer.
  • Options:
    • Accept scoped retention (recommended): Keep accepted install metadata managed across picker returns while retaining the pre-effect rollback boundary for config, account, and hook state.
    • Require full rollback: Discard accepted install metadata as well and require users to repeat installation after returning to the picker.
    • Narrow the shared contract: Keep the Back fix but move any adapter-specific persistence semantics behind a more explicit owner-level contract before merge.

Security
Cleared: The reviewed diff adds no dependency, workflow, secret-handling, permission, or external code-execution surface; the main remaining concern is lifecycle compatibility rather than security.

Review details

Best possible solution:

Have the setup-area owner confirm the scoped rollback and accepted-install retention contract, then merge only after the exact current head has completed its required checks.

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

No high-confidence before-fix reproduction was established in this read-only review. The PR supplies focused tests and an after-fix terminal recording, but those do not independently demonstrate the prior current-main failure.

Is this the best way to solve the issue?

Unclear. The Back-navigation implementation is coherent and the earlier changelog blocker was removed, but a setup-area owner must decide whether the proposed persistence boundary is the best permanent shared contract.

AGENTS.md: unclear because the file could not be read completely.

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

Label changes

Label changes:

  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (recording): The PR includes a terminal recording that directly shows the requested Back-navigation behavior across three channel setup flows and a cancellation without saving; private details should remain redacted in any refreshed proof.
  • remove rating: 🦐 gold shrimp: Current PR rating is rating: 🐚 platinum hermit, so this older rating label is no longer current.
  • remove status: ⏳ waiting on author: Current PR status label is status: 👀 ready for maintainer look.

Label justifications:

  • P2: This improves a bounded interactive setup workflow but does not establish an urgent production outage or release-blocking path.
  • merge-risk: 🚨 compatibility: The PR changes which setup effects persist when users navigate backward, including external plugin installation records and post-write-hook handling.
  • 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 PR includes a terminal recording that directly shows the requested Back-navigation behavior across three channel setup flows and a cancellation without saving; private details should remain redacted in any refreshed proof.
  • proof: sufficient: Contributor real behavior proof is sufficient. The PR includes a terminal recording that directly shows the requested Back-navigation behavior across three channel setup flows and a cancellation without saving; private details should remain redacted in any refreshed proof.
  • proof: 🎥 video: Contributor real behavior proof includes video or recording evidence. The PR includes a terminal recording that directly shows the requested Back-navigation behavior across three channel setup flows and a cancellation without saving; private details should remain redacted in any refreshed proof.
Evidence reviewed

PR surface:

Source +215, Tests +738. Total +953 across 9 files.

View PR surface stats
Area Files Added Removed Net
Source 5 294 79 +215
Tests 4 743 5 +738
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 9 1037 84 +953

What I checked:

  • Current head resolves the prior changelog finding: The previous ClawSweeper cycle requested removal of a release-owned changelog entry; the current head includes commit cd88e89c98a08b4073880e975f3c22d4cf30d025 titled “chore: leave changelog to release prep,” so that specific blocker is no longer present. (CHANGELOG.md, cd88e89c98a0)
  • Scoped navigation disables Back at durable-effect boundary: The new scoped channel-step helper calls the declared persistence hook, disables Back navigation, then delegates to any existing persistence hook; this is the central compatibility boundary requiring owner review. (src/flows/channel-setup-navigation.ts:18, cd88e89c98a0)
  • Rollback behavior has targeted regression coverage: The PR adds channel-setup coverage for returning to the picker before installation and for rollback/retention behavior, plus command and Reef persistence-boundary tests. (src/flows/channel-setup.test.ts:705, cd88e89c98a0)
  • Real terminal behavior is demonstrated: The PR body links a terminal recording showing ClickClack, Discord, and Google Chat returning from their first setup prompt to the shared picker, followed by Ctrl-C cancellation without saving. (6fd84fe7335c)
  • Protected maintainer handling applies: The live item context identifies the author association as MEMBER and includes the maintainer label; repository policy requires explicit maintainer handling rather than auto-close cleanup. (cd88e89c98a0)

Likely related people:

  • jesse-merhi: Authored this navigation change and the linked open setup-wizard PR that introduces the related shared cancellation and persistence contract. (role: related setup-contract contributor; confidence: medium; commits: c1981b62b533, cd88e89c98a0, ec905c1f8d3e; files: src/flows/channel-setup.ts, src/flows/channel-setup-navigation.ts, src/wizard/navigation-prompter.ts)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

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.

How this review workflow works
  • 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.
Review history (10 earlier review cycles; latest 8 shown)
  • reviewed 2026-07-16T02:34:21.979Z sha 27b4d0e :: needs maintainer review before merge. :: none
  • reviewed 2026-07-16T03:31:10.815Z sha 27b4d0e :: needs maintainer review before merge. :: none
  • reviewed 2026-07-19T16:53:01.898Z sha 6fd84fe :: needs maintainer review before merge. :: none
  • reviewed 2026-07-19T17:18:17.583Z sha 6fd84fe :: needs maintainer review before merge. :: none
  • reviewed 2026-07-19T17:27:34.194Z sha 6fd84fe :: needs maintainer review before merge. :: none
  • reviewed 2026-07-19T17:43:05.275Z sha 6fd84fe :: needs maintainer review before merge. :: none
  • reviewed 2026-07-20T04:02:55.017Z sha 2722461 :: found issues before merge. :: [P2] Remove the release-owned changelog entry
  • reviewed 2026-07-20T04:12:02.621Z sha 4afc5a3 :: found issues before merge. :: [P2] Remove the release-owned changelog entry

@clawsweeper clawsweeper Bot added 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. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Jul 16, 2026
@jesse-merhi jesse-merhi self-assigned this Jul 19, 2026
@jesse-merhi
jesse-merhi force-pushed the jesse/channel-setup-back-navigation branch 2 times, most recently from bafd9da to 6fd84fe Compare July 19, 2026 14:42
@jesse-merhi

Copy link
Copy Markdown
Member Author

/clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

Re-review progress:

@jesse-merhi
jesse-merhi marked this pull request as ready for review July 19, 2026 15:08
Copilot AI review requested due to automatic review settings July 19, 2026 15:08

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@jesse-merhi

Copy link
Copy Markdown
Member Author

/clawsweeper re-review

@jesse-merhi
jesse-merhi force-pushed the jesse/channel-setup-back-navigation branch from 6fd84fe to 2722461 Compare July 20, 2026 03:59
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed 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 Jul 20, 2026
@clawsweeper clawsweeper Bot added 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. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Jul 20, 2026
@jesse-merhi
jesse-merhi merged commit ce9e393 into main Jul 20, 2026
136 of 142 checks passed
@jesse-merhi
jesse-merhi deleted the jesse/channel-setup-back-navigation branch July 20, 2026 04:34
@jesse-merhi

Copy link
Copy Markdown
Member Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Jul 20, 2026
* fix: support Back within channel setup

* docs: note channel setup Back navigation

* fix: keep navigation outcome type private

* style: format navigation outcome type

* chore: leave changelog to release prep
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

channel: reef Channel integration: reef commands Command implementations maintainer Maintainer-authored PR merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P2 Normal backlog priority with limited blast radius. 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

Development

Successfully merging this pull request may close these issues.

2 participants