Repository navigation
fix(commands): validate native settings and preserve Telegram ingress outcomes - #116773
Conversation
|
Codex review: needs maintainer review before merge. Reviewed July 31, 2026, 7:30 AM ET / 11:30 UTC. ClawSweeper reviewWhat this changesThis PR makes explicit native session-setting commands retain and validate all supplied arguments across chat channels, and carries Telegram middleware terminal outcomes back to durable ingress despite grammY returning no result. Merge readinessKeep this PR open for explicit maintainer review. The supplied live Telegram evidence directly shows the corrected invalid-command replies, while the branch expands an already-merged queue fix into shared native-command parsing and Telegram durable-ingress outcome ownership; its protected Priority: P1 Review scores
Verification
How this fits togetherNative slash commands enter the reply-directive pipeline before an agent/model turn; this change marks explicitly invoked settings commands as directive-only so malformed arguments receive a command error rather than becoming ordinary prose. In Telegram, durable ingress dispatches updates through grammY middleware, and the change preserves the middleware-owned terminal outcome for retry, skip, and completion handling. flowchart LR
A[Chat native command] --> B[Command registry]
B --> C[Strict directive parsing]
C --> D[Directive-only validation]
D --> E[Visible command reply]
F[Telegram durable ingress] --> G[grammY middleware]
G --> H[Recorded terminal outcome]
H --> F
Decision needed
Why: The patch changes a P1 message-delivery path and is deliberately protected with the Before merge
Agent review detailsSecurityNone. PR surfaceSource +165, Tests +338, Other +48. Total +551 across 22 files. View PR surface stats
Review metrics
Merge-risk optionsMaintainer options:
Copy recommended automerge instructionTechnical reviewBest possible solution: Merge only after maintainers confirm the shared strict-native-command behavior and exact-head checks show that explicit skipped, retryable, and deferred Telegram outcomes remain authoritative through durable ingress. Do we have a high-confidence way to reproduce the issue? No high-confidence current-main failure reproduction is needed for the original queue defect because it was already merged through #116726. The broader malformed-native-command and Telegram outcome paths are source-reproducible and have supplied focused plus live Telegram evidence, but exact-head CI is still running. Is this the best way to solve the issue? Yes, likely: resolving the invoked command through the existing registry and preserving an ingress-owned terminal fact avoids parallel queue policy and prevents ordinary inline-prose parsing from erasing native arguments. Maintainers should still confirm the broader command and delivery boundary before merge. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 95df2dfd6a61. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (2 earlier review cycles)
|
bd92012 to
0cb72a6
Compare
Mantis Telegram Live QASummary: Mantis ran the Telegram live QA lane with Convex-leased credentials, rendered a redacted transcript in a Crabbox desktop browser, and captured screenshot/video evidence for PR review.
Telegram live transcript Telegram motion preview Motion-trimmed clips: Full videos: |
|
Merged via squash.
|
* commit 'd8f229f2e6c39e2dc694730c2efc479e4fb3871e': (59 commits) fix(setup): isolate failed channel probes and report doctor diagnostics (openclaw#116824) fix(telegram): preserve edit previews, message cache, and group history (openclaw#116818) fix(whatsapp): preserve interactive replies and normalize media MIME (openclaw#116816) fix(file-transfer): keep fetched media attachable in sandboxed replies (openclaw#116400) fix(browser): preserve doctor JSON failure status (openclaw#116811) fix(ollama): stream native tool call lifecycle (openclaw#116809) fix(matrix): preserve message-tool room thread routing (openclaw#116802) fix(ui): restore mobile navigation and accessible usage filters (openclaw#116751) fix(ui): coalesce profile identity refresh (openclaw#116764) fix(ui): preserve chat attachments and run ownership (openclaw#116752) fix(plugins): clean up partial service startup once (openclaw#116804) fix(qa-channel): enforce message and thread lifecycle ownership (openclaw#116801) fix(qa-lab): support groups and isolate thread timelines (openclaw#116803) feat(plugins): externalize Voyage embeddings (openclaw#116785) fix(outbound): strip echoed inbound metadata before delivery (openclaw#50520) fix(anthropic-vertex): correct multi-region endpoints (openclaw#116757) fix(ui): scope agent cron jobs and surface model catalog failures (openclaw#116771) fix(ui): preserve scoped session state across updates (openclaw#116772) fix(build): fail closed on symlinked build output roots (openclaw#116705) fix(commands): validate native settings and preserve Telegram ingress outcomes (openclaw#116773) ...
* origin/main: (52 commits) fix(setup): isolate failed channel probes and report doctor diagnostics (openclaw#116824) fix(telegram): preserve edit previews, message cache, and group history (openclaw#116818) fix(whatsapp): preserve interactive replies and normalize media MIME (openclaw#116816) fix(file-transfer): keep fetched media attachable in sandboxed replies (openclaw#116400) fix(browser): preserve doctor JSON failure status (openclaw#116811) fix(ollama): stream native tool call lifecycle (openclaw#116809) fix(matrix): preserve message-tool room thread routing (openclaw#116802) fix(ui): restore mobile navigation and accessible usage filters (openclaw#116751) fix(ui): coalesce profile identity refresh (openclaw#116764) fix(ui): preserve chat attachments and run ownership (openclaw#116752) fix(plugins): clean up partial service startup once (openclaw#116804) fix(qa-channel): enforce message and thread lifecycle ownership (openclaw#116801) fix(qa-lab): support groups and isolate thread timelines (openclaw#116803) feat(plugins): externalize Voyage embeddings (openclaw#116785) fix(outbound): strip echoed inbound metadata before delivery (openclaw#50520) fix(anthropic-vertex): correct multi-region endpoints (openclaw#116757) fix(ui): scope agent cron jobs and surface model catalog failures (openclaw#116771) fix(ui): preserve scoped session state across updates (openclaw#116772) fix(build): fail closed on symlinked build output roots (openclaw#116705) fix(commands): validate native settings and preserve Telegram ingress outcomes (openclaw#116773) ...
* commit 'd8f229f2e6c39e2dc694730c2efc479e4fb3871e': (60 commits) fix(setup): isolate failed channel probes and report doctor diagnostics (openclaw#116824) fix(telegram): preserve edit previews, message cache, and group history (openclaw#116818) fix(whatsapp): preserve interactive replies and normalize media MIME (openclaw#116816) fix(file-transfer): keep fetched media attachable in sandboxed replies (openclaw#116400) fix(browser): preserve doctor JSON failure status (openclaw#116811) fix(ollama): stream native tool call lifecycle (openclaw#116809) fix(matrix): preserve message-tool room thread routing (openclaw#116802) fix(ui): restore mobile navigation and accessible usage filters (openclaw#116751) fix(ui): coalesce profile identity refresh (openclaw#116764) fix(ui): preserve chat attachments and run ownership (openclaw#116752) fix(plugins): clean up partial service startup once (openclaw#116804) fix(qa-channel): enforce message and thread lifecycle ownership (openclaw#116801) fix(qa-lab): support groups and isolate thread timelines (openclaw#116803) feat(plugins): externalize Voyage embeddings (openclaw#116785) fix(outbound): strip echoed inbound metadata before delivery (openclaw#50520) fix(anthropic-vertex): correct multi-region endpoints (openclaw#116757) fix(ui): scope agent cron jobs and surface model catalog failures (openclaw#116771) fix(ui): preserve scoped session state across updates (openclaw#116772) fix(build): fail closed on symlinked build output roots (openclaw#116705) fix(commands): validate native settings and preserve Telegram ingress outcomes (openclaw#116773) ...
… outcomes (openclaw#116773) * fix(commands): validate native directives and preserve Telegram outcomes * test(commands): isolate native directive fast runtime --------- Co-authored-by: Peter Steinberger <[email protected]>
* commit '4e7fffdb98ce4d3e6fd69859bedd584cf474ec53': (59 commits) fix(setup): isolate failed channel probes and report doctor diagnostics (openclaw#116824) fix(telegram): preserve edit previews, message cache, and group history (openclaw#116818) fix(whatsapp): preserve interactive replies and normalize media MIME (openclaw#116816) fix(file-transfer): keep fetched media attachable in sandboxed replies (openclaw#116400) fix(browser): preserve doctor JSON failure status (openclaw#116811) fix(ollama): stream native tool call lifecycle (openclaw#116809) fix(matrix): preserve message-tool room thread routing (openclaw#116802) fix(ui): restore mobile navigation and accessible usage filters (openclaw#116751) fix(ui): coalesce profile identity refresh (openclaw#116764) fix(ui): preserve chat attachments and run ownership (openclaw#116752) fix(plugins): clean up partial service startup once (openclaw#116804) fix(qa-channel): enforce message and thread lifecycle ownership (openclaw#116801) fix(qa-lab): support groups and isolate thread timelines (openclaw#116803) feat(plugins): externalize Voyage embeddings (openclaw#116785) fix(outbound): strip echoed inbound metadata before delivery (openclaw#50520) fix(anthropic-vertex): correct multi-region endpoints (openclaw#116757) fix(ui): scope agent cron jobs and surface model catalog failures (openclaw#116771) fix(ui): preserve scoped session state across updates (openclaw#116772) fix(build): fail closed on symlinked build output roots (openclaw#116705) fix(commands): validate native settings and preserve Telegram ingress outcomes (openclaw#116773) ...
* origin/main: (52 commits) fix(setup): isolate failed channel probes and report doctor diagnostics (openclaw#116824) fix(telegram): preserve edit previews, message cache, and group history (openclaw#116818) fix(whatsapp): preserve interactive replies and normalize media MIME (openclaw#116816) fix(file-transfer): keep fetched media attachable in sandboxed replies (openclaw#116400) fix(browser): preserve doctor JSON failure status (openclaw#116811) fix(ollama): stream native tool call lifecycle (openclaw#116809) fix(matrix): preserve message-tool room thread routing (openclaw#116802) fix(ui): restore mobile navigation and accessible usage filters (openclaw#116751) fix(ui): coalesce profile identity refresh (openclaw#116764) fix(ui): preserve chat attachments and run ownership (openclaw#116752) fix(plugins): clean up partial service startup once (openclaw#116804) fix(qa-channel): enforce message and thread lifecycle ownership (openclaw#116801) fix(qa-lab): support groups and isolate thread timelines (openclaw#116803) feat(plugins): externalize Voyage embeddings (openclaw#116785) fix(outbound): strip echoed inbound metadata before delivery (openclaw#50520) fix(anthropic-vertex): correct multi-region endpoints (openclaw#116757) fix(ui): scope agent cron jobs and surface model catalog failures (openclaw#116771) fix(ui): preserve scoped session state across updates (openclaw#116772) fix(build): fail closed on symlinked build output roots (openclaw#116705) fix(commands): validate native settings and preserve Telegram ingress outcomes (openclaw#116773) ...
* commit '4e7fffdb98ce4d3e6fd69859bedd584cf474ec53': (60 commits) fix(setup): isolate failed channel probes and report doctor diagnostics (openclaw#116824) fix(telegram): preserve edit previews, message cache, and group history (openclaw#116818) fix(whatsapp): preserve interactive replies and normalize media MIME (openclaw#116816) fix(file-transfer): keep fetched media attachable in sandboxed replies (openclaw#116400) fix(browser): preserve doctor JSON failure status (openclaw#116811) fix(ollama): stream native tool call lifecycle (openclaw#116809) fix(matrix): preserve message-tool room thread routing (openclaw#116802) fix(ui): restore mobile navigation and accessible usage filters (openclaw#116751) fix(ui): coalesce profile identity refresh (openclaw#116764) fix(ui): preserve chat attachments and run ownership (openclaw#116752) fix(plugins): clean up partial service startup once (openclaw#116804) fix(qa-channel): enforce message and thread lifecycle ownership (openclaw#116801) fix(qa-lab): support groups and isolate thread timelines (openclaw#116803) feat(plugins): externalize Voyage embeddings (openclaw#116785) fix(outbound): strip echoed inbound metadata before delivery (openclaw#50520) fix(anthropic-vertex): correct multi-region endpoints (openclaw#116757) fix(ui): scope agent cron jobs and surface model catalog failures (openclaw#116771) fix(ui): preserve scoped session state across updates (openclaw#116772) fix(build): fail closed on symlinked build output roots (openclaw#116705) fix(commands): validate native settings and preserve Telegram ingress outcomes (openclaw#116773) ...
Backport the durable ingress outcome handoff from openclaw#116773. Co-authored-by: Peter Steinberger <[email protected]>
… outcomes (openclaw#116773) * fix(commands): validate native directives and preserve Telegram outcomes * test(commands): isolate native directive fast runtime --------- Co-authored-by: Peter Steinberger <[email protected]> (cherry picked from commit 1a0fde1)


Related: #116688
Follow-up to #116726
What Problem This Solves
Fixes an issue where Telegram, Discord, and Slack users invoking native session-settings commands with malformed or trailing arguments could lose those arguments, fall through to ordinary message handling, and receive misleading model-failure replies. Telegram's durable ingress also discarded each command's terminal processing outcome because grammY
handleUpdatereturnsvoid.Why This Change Was Made
Resolve native directives from the existing command registry, parse only the explicitly invoked command in strict command mode, and route validation through the canonical directive-only pipeline without duplicating queue policy. Reuse the ingress-owned Telegram processing frame through bot middleware and return its recorded outcome to the durable drain while preserving skipped, retryable, and deferred-adoption semantics.
User Impact
Native
/queue,/think,/verbose,/trace,/fast,/reasoning,/elevated,/exec, and/modelcommands now either perform their documented setting change or return a precise argument error. Ordinary inline prose semantics remain unchanged. Telegram command updates now produce explicit durable processing outcomes.Evidence
pnpm check:changed: all-project TypeScript, core/plugin/script lint, dead-export, SDK ownership, import-cycle, and policy gates passed.OPENCLAW_BUILD_PRIVATE_QA=1 pnpm build: production and private-QA bundles passed.telegram-queue-invalid-modereal Telegram QA scenario covers invalid queue modes, unexpected trailing queue arguments, and invalid thinking levels.OPENCLAW_*variables while its checked-in ratchet still said 518; aligned the required budget with the verified source count.Live Telegram Proof
Mantis Telegram Live run 30627149777 passed the real Telegram scenario using Convex-leased credentials and AWS Crabbox. The exact final reviewed PR head
bb8d9dc0e9ebe67c8387c13ccd4a3d0e210c344cpassed the real Telegram scenario after merge./queue Can you diagnose this?→Unrecognized queue mode "Can". Valid modes: steer, followup, collect, interrupt./queue collect please help→Unexpected argument "please" for /queue./think about my deployment plan→Unrecognized thinking level "about". Valid levels: default, off, minimal, low, medium, high, xhigh, max, ultra.