Skip to content

Add inline exec approval flow#751

Open
RBrid wants to merge 1 commit into
openclaw:mainfrom
RBrid:user/rbrid/InlineApproval
Open

Add inline exec approval flow#751
RBrid wants to merge 1 commit into
openclaw:mainfrom
RBrid:user/rbrid/InlineApproval

Conversation

@RBrid

@RBrid RBrid commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Route local exec approval prompts into the active chat timeline when session context is available, including allow-once, always-allow, deny, resolved-state stamping, and local prompt cancellation handling. Preserve native prompt fallback for requests without chat context.

Thread session keys through node.invoke request/event paths and system.run approvals while preserving trusted envelope metadata over command args. Keep legacy policy compatibility by accepting ask/prompt/numeric action values and preserving stable ChatPermissionDecision enum values.

Update the permissions UI to use canonical prompt actions, upsert exact duplicate command patterns, safely coalesce duplicate loaded rules without changing first-match semantics, and refresh localized approval copy for allow-once versus always-allow behavior.

Add regression coverage for inline approval decisions, session-key propagation, duplicate policy rule handling, legacy policy deserialization, enum stability, and action-button fallback behavior.

Proof Screenshots:

Type of (cut-off) UI that's moved inline into the chat history ...
image

... in order to align with existing inline approval UI:
image

This is the resulting UI:
image

image

Also fixing the incomplete custom rule combobox:
image

Testing and review

  • Build: ./build.ps1 passed after resolving PR Add app notifications surface #748 conflicts.
  • Shared unit tests: dotnet test ./tests/OpenClaw.Shared.Tests/OpenClaw.Shared.Tests.csproj --no-restore passed (2243 passed, 29 skipped).
  • Tray unit tests: dotnet test ./tests/OpenClaw.Tray.Tests/OpenClaw.Tray.Tests.csproj --no-restore passed (1073 passed).
  • Manual testing: launched the Debug WinUI app from user/rbrid/InlineApproval with ./run-app-local.ps1 -NoBuild -AllowNonMain and used the screenshots above to validate the inline approval and permissions combobox UI.
  • Auto-review: ran the bundled autoreview helper; final run was clean with no accepted/actionable findings (python .agents/skills/autoreview/scripts/autoreview --mode local --engine copilot, with PYTHONUTF8=1 and AUTOREVIEW_ALLOW_UNSANDBOXED_TOOLS=1; default Codex engine was unavailable because codex is not installed locally).
  • Hanselman review: ran dual-model review (Opus + Codex rubber-duck reviewers); accepted findings were fixed, then validation and autoreview were rerun clean.

Route local exec approval prompts into the active chat timeline when session context is available, including allow-once, always-allow, deny, resolved-state stamping, and local prompt cancellation handling. Preserve native prompt fallback for requests without chat context.

Thread session keys through node.invoke request/event paths and system.run approvals while preserving trusted envelope metadata over command args. Keep legacy policy compatibility by accepting ask/prompt/numeric action values and preserving stable ChatPermissionDecision enum values.

Update the permissions UI to use canonical prompt actions, upsert exact duplicate command patterns, safely coalesce duplicate loaded rules without changing first-match semantics, and refresh localized approval copy for allow-once versus always-allow behavior.

Add regression coverage for inline approval decisions, session-key propagation, duplicate policy rule handling, legacy policy deserialization, enum stability, and action-button fallback behavior.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@clawsweeper

clawsweeper Bot commented Jun 12, 2026

Copy link
Copy Markdown

Codex review: needs real behavior proof before merge. Reviewed June 12, 2026, 6:24 PM ET / 22:24 UTC.

Summary
Review failed before ClawSweeper could summarize the requested change.

Reproducibility: unclear. The review failed before ClawSweeper could establish a reproduction path.

Review metrics: none identified.

Merge readiness
Overall: 🌊 off-meta tidepool
Proof: 🌊 off-meta tidepool
Patch quality: 🌊 off-meta tidepool
Result: rating does not apply to this item.

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

Risk before merge

  • [P1] No close action taken because the review did not complete.

Maintainer options:

  1. Decide the mitigation before merge
    Retry the Codex review after fixing the execution failure.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • [P1] Review did not complete, so no work-lane recommendation was made.
Review details

Best possible solution:

Retry the Codex review after fixing the execution failure.

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

Unclear. The review failed before ClawSweeper could establish a reproduction path.

Is this the best way to solve the issue?

Unclear. Retry the review first so ClawSweeper can evaluate the actual issue and fix direction.

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

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

Label changes

Label justifications:

  • rating: 🌊 off-meta tidepool: Overall readiness is 🌊 off-meta tidepool; proof is 🌊 off-meta tidepool and patch quality is 🌊 off-meta tidepool.
Evidence reviewed

What I checked:

  • failure reason: codex execution failed.
  • codex failure detail: Codex review failed for this PR with exit 1.
  • codex stderr: ResolvedEcho_WithAllowDecision_MarksEntryAllowedNotExpired()\n Assert.Null(snapshots[^1].Timelines["main"].PendingPermission);\n }\n \n+ [Fact]\n+ public async Task ResolvedEcho_WithAllowAlwaysDecision_MarksEntryAlwaysAllowed()\n+ {\n+ var (bridge, provider, snapshots, _) = CreateProvider(new[] { MainSession() });\n+ await provider.LoadAsync();\n+\n+ bridge.RaiseAgen\n\n[truncated 3663 chars]".
  • codex stdout: No stdout captured.

Likely related people:

  • unknown: Codex failed before it could trace repository history. (role: review did not complete; confidence: low)
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.

@clawsweeper clawsweeper Bot added the rating: 🌊 off-meta tidepool PR readiness rating does not apply to this item. label Jun 12, 2026
@RBrid

RBrid commented Jun 12, 2026

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jun 12, 2026

Copy link
Copy Markdown

🦞🧹
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:

@RBrid RBrid marked this pull request as ready for review June 12, 2026 22:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rating: 🌊 off-meta tidepool PR readiness rating does not apply to this item.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant