fix(telegram): explain disabled plugin approval failures#95973
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 638d5ce825
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 193c044912
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@clawsweeper re-review Current head |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
Codex review: needs maintainer review before merge. Reviewed July 2, 2026, 5:12 PM ET / 21:12 UTC. Summary PR surface: Source +303, Tests +827, Docs +25, Config 0, Other +887. Total +2042 across 79 files. Reproducibility: yes. The linked issue and prior review source-reproduced the generic Telegram plugin approval no-route/timeout path, and the Mantis before/after proof shows baseline generic failure text versus candidate setup guidance. Review metrics: 2 noteworthy metrics.
Stored data model Root-cause cluster Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Risk before merge
Maintainer options:
Next step before merge
Security Review detailsBest possible solution: Land the focused approval-failure guidance once exact-head checks and guard state agree with the potential merge result, keeping approver authorization separate from native delivery/setup guidance. Do we have a high-confidence way to reproduce the issue? Yes. The linked issue and prior review source-reproduced the generic Telegram plugin approval no-route/timeout path, and the Mantis before/after proof shows baseline generic failure text versus candidate setup guidance. Is this the best way to solve the issue? Yes. Appending channel-owned plugin setup guidance only when the plugin hook exists and native delivery is disabled is the narrow fix; auto-routing, doctor hints, or broader discoverability can remain follow-up work. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 968aa51b8000. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +303, Tests +827, Docs +25, Config 0, Other +887. Total +2042 across 79 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
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
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: da449cf6be
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
da449cf to
ca2e0b1
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ca2e0b1244
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Superseded by the latest patch-quality fix and PR body refresh. Current head The current head also adds split-route regression coverage so channels with exec setup text but no plugin setup capability do not receive misleading exec setup instructions for plugin approval failures. |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
@clawsweeper re-review Current head No implementation changes were made for this proof-only refresh. |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
@openclaw-mantis Telegram visible proof. Compare this PR head with its baseline using a real Telegram user in Crabbox. Configure Telegram so native exec/plugin approvals have no configured approver: omit or disable Required proof: baseline lacks actionable Telegram setup guidance; candidate explains how to enable |
This reverts commit 34e3c10.
|
@openclaw-mantis Telegram visible proof. Retry the exact-head comparison for PR #95973. Prior run 28614561109 skipped both baseline and candidate because the shared Telegram Desktop session was unavailable; it did not test or find a product failure. Compare current PR head 3ff1c41 with its baseline using a real Telegram user in Crabbox. Configure Telegram with no native exec/plugin approval route: omit or disable Required proof: baseline lacks actionable Telegram setup guidance; candidate explains how to enable |
|
@mantis please rerun the Telegram Desktop comparison for exact candidate head The previous run correctly exercised the real Telegram/Gateway path, but the default For this proof only, in each detached proof worktree, use an uncommitted temporary mock response that:
Keep the real Telegram user, Telegram transport, Gateway, agent tool loop, and Crabbox Desktop verification unchanged. Only the deterministic mock model response should differ from the standard proof setup. Required comparison:
Please publish the before/after Telegram Desktop evidence and exact refs used. |
|
@openclaw-mantis please rerun the Telegram Desktop proof comparison for exact candidate head The previous run correctly exercised the real Telegram/Gateway path, but the default For this proof only, in each detached proof worktree, use an uncommitted temporary mock response that:
Keep the real Telegram user, Telegram transport, Gateway, agent tool loop, and Crabbox Desktop verification unchanged. Only the deterministic mock model response should differ from the standard proof setup. Required comparison:
Please publish the before/after Telegram Desktop evidence and exact refs used. |
|
Hi, Not a member of this project |
Mantis Telegram Desktop ProofSummary: Mantis captured native Telegram Desktop before/after GIF evidence for Telegram plugin approval setup guidance.
Motion-trimmed clips: |
Land-ready maintainer proofThe maintainer pass tightened the cross-channel behavior before landing:
Validation on exact candidate head
The Mantis workflow's product proof job passed. Its overall run is red only because the final, unrelated cleanup step could not remove the workflow's eyes reaction ( Review artifacts validate with zero findings and zero proof gaps. Ready to land. |
Dependency GuardThis PR changes dependency-related files. Maintainers should confirm these changes are intentional. Changed files:
Maintainer follow-up:
|
Dependency graph change authorizedThis PR includes dependency graph changes. A repository admin or member of
A later push changes the PR head SHA and requires a fresh security approval. |
|
Hi, Not a member of this project - receiving multiple spam emails from this ticket. |
|
/allow-dependencies-change Verified wrapper-sync false positive: the GraphQL verified sync commit keeps the old PR head as its parent while copying the rebased tree. All reported dependency files are byte-identical to current origin/main; the actual origin/main..c6c170b PR diff is unchanged from the reviewed/live-tested 15-file patch (SHA-256 131bbc4a36c98e3b27bfeb618df319c42757fcab9cf47abfe724f66c87674c36) and contains no dependency files. |
|
Merged via squash.
|




What Problem This Solves
Fixes #95800.
Telegram-originated plugin approvals, such as
skill_workshop apply, could fail with a generic no-route or timeout message when Telegram native approvals were unavailable becausechannels.telegram.execApprovals.approversandcommands.ownerAllowFromwere not configured. The Telegram setup guidance already existed, but the agent-facing plugin approval failure did not surface it.Why This Change Was Made
The approval hook already receives the turn source. This PR updates the agent-side plugin approval no-route failure path so it can append channel setup guidance when the initiating channel's native plugin approval delivery route is disabled and that channel exposes plugin-specific setup text.
Accepted plugin approval timeouts now use the gateway's accepted-route marker: delivered prompts remain plain
Approval timed out, while requests kept pending only by turn-source approval routing receive the same setup guidance. Visible approval clients no longer mask that turn-source marker, because a native approval runtime can be connected and still skip a request via its ownshouldHandlelogic.The setup text is plugin-surface aware. Split-route channels with exec setup text but no plugin setup capability keep the generic plugin approval failure instead of receiving misleading exec setup instructions.
The final compatibility shape keeps approval authorization separate from native delivery setup guidance. Plugin approval availability used by
/approve plugin:<id>remains based on configured approvers, so forwarded approvals from authorized operators still work even when native Telegram delivery is disabled. The native delivery state is used only to decide whether the failure reason should include setup guidance.This keeps the current approver-gating model intact and does not auto-route, auto-approve, or enable Telegram approvals.
User Impact
Telegram-only operators get an actionable explanation telling them to use Web UI or terminal UI for now, or configure
channels.telegram.execApprovals.approvers/commands.ownerAllowFrom, instead of a silent timeout-shaped denial.Operators on split-route channels are not told to enable exec approvals for plugin approval failures unless the channel explicitly exposes plugin approval setup guidance.
Authorized approvers can still resolve forwarded
plugin:<id>approvals even when native Telegram delivery is disabled.Plugin authors now have documented guidance for
approvalCapability.describePluginApprovalSetup, including that approver availability and native delivery availability are separate concerns.Evidence
90b7832dfe3a46055cd114cac59de1192418b514.34e3c10e23ec8d3cf00ff803188df4226cd60f8dwas reverted bye924d2813c19d808fa1a583da03b10b642d162f2; this body describes only the current PR diff.59039ea530878706fdd70fad22eb2fcfee573b05addresses the compatibility blocker by preserving approver-based plugin approval availability while using native delivery state only for setup guidance.d348ee93e666697bb8aa55f83a00d069f2dd5801addresses the split-route setup-copy blocker by removing the SDK helper-wide fallback from exec setup guidance to plugin setup guidance. Telegram now opts in explicitly because its plugin and exec approval setup guidance intentionally match; Slack does not opt in, so plugin approval failures cannot inherit Slack exec setup copy.b2faa9098063346dfdc47f08ed81b26087bcf1e2removed the earlier broad e2e regression additions without changing runtime behavior.e68cfa2cd8adc25344b45814994f753fcaa370c1addressed the routed-timeout blocker by keeping setup guidance out of blindly accepted timeouts.179c4920fc961957020d8de620f8bd83ac4cdb2baddresses the accepted-but-undelivered timeout blocker by carrying the gateway accepted-route marker into the agent timeout branch;deliveryRoute: "turn-source"gets setup guidance, while delivered routes stay plain timeouts.90b7832dfe3a46055cd114cac59de1192418b514addresses the visible-approval-client route blocker by letting turn-source routing stay explicit when a visible approval client exists but no delivery confirms. The focused regression covers a connected approval client plus an available turn-source route and asserts the accepted response reportsdeliveryRoute: "turn-source".Real behavior proof for the user-facing Telegram failure path, captured on this PR branch at
858a7b2dda28a07982af45e01caad1b50644765b:Run setup:
Observed output:
This is not a unit-test-only proof: the run used the real agent approval hook and real Gateway plugin approval request path. The provider was
mock-openai, which is not involved in plugin approval routing. The current-head patch keeps that Telegram no-route failure reason intact and narrows the accepted-timeout classification around actual delivery versus turn-source-only routing.Current-head focused regression proof for
90b7832dfe3a46055cd114cac59de1192418b514:Result: 2 Vitest shards passed. Gateway shard: 4 files passed, 114 tests passed. E2E shard: 1 file passed, 58 tests passed.
Result: 2 Vitest shards passed. Infra shard: 2 files passed, 27 tests passed. Plugin SDK shard: 1 file passed, 7 tests passed.
Result: all passed.
pnpm buildemitted the existing Vite large-chunk warning for the control UI bundle.The focused coverage asserts:
/approve plugin:<id>behavior.Approval timed out.turn-sourcedelivery marker when no delivery confirms, so a connected runtime that skips the request cannot hide setup guidance on timeout.Autoreview note:
.agents/skills/autoreview/scripts/autoreview --mode localcould not start because the local Codex CLI config hasservice_tier=priority, which this helper rejects as an unknown variant; it expectedfastorflex. It failed before reviewing code; no autoreview findings were produced.GitHub checks for
90b7832dfe3a46055cd114cac59de1192418b514are queued/running after the latest push.Notes
openclaw/openclawfailed with GitHub 403, so this PR is from theMonkeyLeeT/openclawfork with maintainer edits enabled.@steipetealso failed from this token with GitHub 403.