Repository navigation
fix(telegram): expose live location updates to hooks - #122185
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
4304a15 to
b37bbab
Compare
|
Codex review: needs maintainer review before merge. Reviewed August 11, 2026, 5:05 PM ET / 21:05 UTC. ClawSweeper reviewWhat this changesThe PR adds normalized location and provider-update data to plugin message hooks and sends authorized Telegram live-location edits to observers without starting an agent turn. Merge readinessKeep this protected PR open for a clean rebase and real Telegram behavior proof. The prior channel-post and nonblocking-dispatch findings are addressed on the current head; no new code correctness defect was found. Priority: P2 Review scores
Verification
How this fits togetherTelegram inbound updates are authorized and normalized before either agent dispatch or plugin observation. This change adds an observer-only route for edited live locations while preserving normal agent-turn behavior. flowchart LR
A[Telegram update] --> B[Inbound authorization]
B --> C{Edited live location}
C -->|yes| D[Nonblocking message hook]
C -->|no| E[Normal inbound dispatch]
D --> F[Plugin observers]
E --> G[Agent turn]
Before merge
Agent review detailsSecurityNone. PR surfaceSource +234, Tests +225, Docs +2, Generated 0, Other +1. Total +462 across 48 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Mantis proof suggestionA Telegram Desktop recording can directly verify the changed live-location observer flow and absence of agent dispatch. A maintainer can ask Mantis to capture proof by posting this exact PR comment: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep the channel-neutral optional hook contract, then rebase cleanly and attach a redacted Telegram trace or recording that shows an edited live location reaching a plugin hook without creating an agent turn. Do we have a high-confidence way to reproduce the issue? Yes, from source: the base edited-update path only recorded reply-chain context, while the PR head emits an authorized edited-location observer event. A live Telegram reproduction was not supplied. Is this the best way to solve the issue? Yes, subject to rebase and live proof: the channel-owned emitter records provider facts at the Telegram boundary and reuses the canonical hook mapper rather than sending edits through agent dispatch. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against c2ad148cb8b7. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
# Conflicts: # docs/.generated/plugin-sdk-api-baseline/agent-harness-runtime.json # docs/.generated/plugin-sdk-api-baseline/agent-harness.json # docs/.generated/plugin-sdk-api-baseline/agent-runtime.json # docs/.generated/plugin-sdk-api-baseline/channel-core.json # docs/.generated/plugin-sdk-api-baseline/channel-entry-contract.json # docs/.generated/plugin-sdk-api-baseline/channel-inbound.json # docs/.generated/plugin-sdk-api-baseline/channel-message.json # docs/.generated/plugin-sdk-api-baseline/channel-outbound.json # docs/.generated/plugin-sdk-api-baseline/channel-pairing.json # docs/.generated/plugin-sdk-api-baseline/channel-plugin-common.json # docs/.generated/plugin-sdk-api-baseline/core.json # docs/.generated/plugin-sdk-api-baseline/discord.json # docs/.generated/plugin-sdk-api-baseline/inbound-reply-dispatch.json # docs/.generated/plugin-sdk-api-baseline/meeting-runtime.json # docs/.generated/plugin-sdk-api-baseline/plugin-entry.json # docs/.generated/plugin-sdk-api-baseline/plugin-runtime.json # docs/.generated/plugin-sdk-api-baseline/provider-catalog-runtime.json # docs/.generated/plugin-sdk-api-baseline/runtime-store.json # docs/.generated/plugin-sdk-api-baseline/session-catalog.json # docs/.generated/plugin-sdk-api-baseline/tool-plugin.json # docs/.generated/plugin-sdk-api-baseline/webhook-ingress.json
# Conflicts: # docs/.generated/plugin-sdk-api-baseline/agent-harness-runtime.json # docs/.generated/plugin-sdk-api-baseline/agent-harness.json # docs/.generated/plugin-sdk-api-baseline/channel-core.json # docs/.generated/plugin-sdk-api-baseline/channel-entry-contract.json # docs/.generated/plugin-sdk-api-baseline/channel-message.json # docs/.generated/plugin-sdk-api-baseline/channel-outbound.json # docs/.generated/plugin-sdk-api-baseline/channel-plugin-common.json # docs/.generated/plugin-sdk-api-baseline/command-auth-native.json # docs/.generated/plugin-sdk-api-baseline/core.json # docs/.generated/plugin-sdk-api-baseline/discord.json # docs/.generated/plugin-sdk-api-baseline/inbound-reply-dispatch.json # docs/.generated/plugin-sdk-api-baseline/meeting-runtime.json # docs/.generated/plugin-sdk-api-baseline/plugin-entry.json # docs/.generated/plugin-sdk-api-baseline/plugin-runtime.json # docs/.generated/plugin-sdk-api-baseline/provider-catalog-runtime.json # docs/.generated/plugin-sdk-api-baseline/tool-plugin.json # docs/.generated/plugin-sdk-api-baseline/webhook-ingress.json
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Maintainer decision: approve the additive channel-neutral |
# Conflicts: # docs/.generated/plugin-sdk-api-baseline/agent-harness-runtime.json # docs/.generated/plugin-sdk-api-baseline/agent-harness.json # docs/.generated/plugin-sdk-api-baseline/agent-runtime.json # docs/.generated/plugin-sdk-api-baseline/channel-contract.json # docs/.generated/plugin-sdk-api-baseline/channel-core.json # docs/.generated/plugin-sdk-api-baseline/channel-entry-contract.json # docs/.generated/plugin-sdk-api-baseline/channel-inbound.json # docs/.generated/plugin-sdk-api-baseline/channel-message.json # docs/.generated/plugin-sdk-api-baseline/channel-outbound.json # docs/.generated/plugin-sdk-api-baseline/channel-pairing.json # docs/.generated/plugin-sdk-api-baseline/channel-plugin-common.json # docs/.generated/plugin-sdk-api-baseline/command-auth-native.json # docs/.generated/plugin-sdk-api-baseline/command-auth.json # docs/.generated/plugin-sdk-api-baseline/config-runtime.json # docs/.generated/plugin-sdk-api-baseline/conversation-runtime.json # docs/.generated/plugin-sdk-api-baseline/core.json # docs/.generated/plugin-sdk-api-baseline/discord.json # docs/.generated/plugin-sdk-api-baseline/hook-runtime.json # docs/.generated/plugin-sdk-api-baseline/inbound-reply-dispatch.json # docs/.generated/plugin-sdk-api-baseline/media-runtime.json # docs/.generated/plugin-sdk-api-baseline/media-understanding-runtime.json # docs/.generated/plugin-sdk-api-baseline/meeting-runtime.json # docs/.generated/plugin-sdk-api-baseline/plugin-entry.json # docs/.generated/plugin-sdk-api-baseline/plugin-runtime.json # docs/.generated/plugin-sdk-api-baseline/provider-catalog-runtime.json # docs/.generated/plugin-sdk-api-baseline/reply-dispatch-runtime.json # docs/.generated/plugin-sdk-api-baseline/reply-runtime.json # docs/.generated/plugin-sdk-api-baseline/runtime-store.json # docs/.generated/plugin-sdk-api-baseline/session-catalog.json # docs/.generated/plugin-sdk-api-baseline/session-store-runtime.json # docs/.generated/plugin-sdk-api-baseline/tool-plugin.json # docs/.generated/plugin-sdk-api-baseline/webhook-ingress.json
# Conflicts: # docs/.generated/plugin-sdk-api-baseline/agent-harness-runtime.json # docs/.generated/plugin-sdk-api-baseline/agent-harness.json # docs/.generated/plugin-sdk-api-baseline/channel-core.json # docs/.generated/plugin-sdk-api-baseline/channel-entry-contract.json # docs/.generated/plugin-sdk-api-baseline/channel-message.json # docs/.generated/plugin-sdk-api-baseline/channel-outbound.json # docs/.generated/plugin-sdk-api-baseline/channel-plugin-common.json # docs/.generated/plugin-sdk-api-baseline/core.json # docs/.generated/plugin-sdk-api-baseline/discord.json # docs/.generated/plugin-sdk-api-baseline/inbound-reply-dispatch.json # docs/.generated/plugin-sdk-api-baseline/meeting-runtime.json # docs/.generated/plugin-sdk-api-baseline/plugin-entry.json # docs/.generated/plugin-sdk-api-baseline/plugin-runtime.json # docs/.generated/plugin-sdk-api-baseline/provider-catalog-runtime.json # docs/.generated/plugin-sdk-api-baseline/tool-plugin.json # docs/.generated/plugin-sdk-api-baseline/webhook-ingress.json
…-prep * commit 'edb7a1692e58d78ff7e196db39ea8eff297b2e19': (1351 commits) fix(telegram): expose live location updates to hooks (openclaw#122185) fix(ui): remove the pre-creation session row (openclaw#122259) fix(openai): surface failed realtime response outcomes (openclaw#121177) fix(logging): publish diagnostics ZIP through staged atomic overwrite (openclaw#122130) test(cli): trim duplicate MCP probe process cases (openclaw#122260) feat(agents): replay persisted native video (openclaw#122257) fix(test): serialize default e2e runner (openclaw#122203) fix(ui): always show full assistant responses (openclaw#122207) feat(mcp): per-requester OAuth for MCP servers (openclaw#122166) fix(ui): preserve focus on composer accessory clicks (openclaw#122243) fix(backup): exclude state temp files (openclaw#122250) fix(browser): let attached workers exit after CDP use (openclaw#122103) test(cli): trim duplicate Claw authoring process cases (openclaw#122248) refactor(outbound): inline delivery diagnostics (openclaw#122219) refactor: eliminate final wrapper-shadowing hazards (openclaw#122157) fix(ui): keep new-session identity anchored (openclaw#122242) test(cli): trim duplicate gateway process cases (openclaw#122240) fix(media): decode local file URLs safely (openclaw#122192) refactor(agents): centralize typed activity event emission (openclaw#122188) fix(ui): effort slider matches selected level after model switches (openclaw#122125) ...
* fix(telegram): expose live location updates to hooks * test(telegram): keep location coverage focused * fix(telegram): emit stopped live locations * test(plugin-sdk): refresh location hook contracts * docs(changelog): note Telegram live location hooks * fix(telegram): complete live-location observer path --------- Co-authored-by: mbelinky <[email protected]>
Summary
message_receivedwithout starting an agent turnWhy
Telegram delivers live-location movement as edited messages. Those edits were cached for replies but were invisible to plugin observers, while the normal inbound mapper also discarded structured location and update identity. Plugins could therefore observe the initial point but not reliably track later movement.
Validation
pnpm tsgo:prodnode scripts/run-vitest.mjs extensions/telegram/src/location-message-hook.test.ts src/hooks/message-hook-mappers.test.ts(31 tests)git diff --checkRelease note
Telegram live-location edits are now observable through the normal plugin message hook without waking the agent. This touches the Plugin SDK message-hook seam and is suitable for inclusion in the active release line.