Repository navigation
Conversation
Greptile SummaryThis PR adds
Confidence Score: 1/5Do not merge — the CODEOWNERS overwrite must be reverted before this PR can proceed. A P0 security finding is present: the CODEOWNERS file is completely replaced in a way that removes all mandatory security-team and release-manager review requirements. This is unrelated to the feature being implemented and matches a supply chain attack pattern. Score is 1 (well below the P0 ceiling of 2) because the finding is on a foundational governance file that affects the entire repository. .github/CODEOWNERS requires immediate attention — it must be reverted to the original 54-line file before any other aspect of this PR is evaluated.
|
|
Thanks for the context here. I swept through the related work, and this is now duplicate or superseded. Keep this PR open: the Telegram poll-vote routing direction is useful, but the current patch is not merge-ready because the registry write is placed above shared send paths, the new runtime registry uses a JSON sidecar that conflicts with repository state policy, CI lint is currently failing, and the available Telegram Desktop proof does not show a successful candidate vote-to-session response. Canonical path: Close this stale PR. The latest review rated it F, the branch still lacks merge-ready proof, and there has been no human follow-up after the durable review. So I’m closing this here because the remaining work is already tracked in the canonical issue. Review detailsBest possible solution: Close this stale PR. The latest review rated it F, the branch still lacks merge-ready proof, and there has been no human follow-up after the durable review. Do we have a high-confidence way to reproduce the issue? Yes. Current main has no poll_answer handler in the Telegram bot handler path while grammY/Bot API types and local default-update expectations include poll_answer, so sending a public Telegram poll and voting has no current route into a session. Is this the best way to solve the issue? No. The proposed handler shape is plausible, but the registry should be owned at the central Telegram poll send/storage boundary instead of only the message-action handler, and the visible Telegram proof must show a successful routed follow-up. Security review: Security review cleared: No concrete security or supply-chain regression remains in the current diff; the earlier CODEOWNERS overwrite is gone, and the new inbound handler uses existing Telegram event authorization before enqueueing. AGENTS.md: found and applied where relevant. What I checked:
Likely related people:
Codex review notes: model internal, reasoning high; reviewed against 7bd533a80e9d. |
c0e1e1b to
8b3ea3d
Compare
78e0847 to
9a15298
Compare
d331110 to
4a46756
Compare
12809d9 to
2673cd5
Compare
|
@openclaw-mantis verify this PR on Telegram Desktop. Please generate before/after GIF evidence for Telegram poll answer routing. Send a public poll through OpenClaw into the proof chat, then vote from Telegram Desktop. The proof should make main show the vote being ignored with no routed agent/session follow-up, and this PR should show the poll vote routed into the session with a visible follow-up response that includes the selected option/context. Prioritize the native Telegram poll and vote-to-response delta. |
Mantis Telegram Desktop ProofSummary: Mantis captured native Telegram Desktop before/after GIF evidence.
Motion-trimmed clips: |
|
ClawSweeper PR egg 🎁 Pass real behavior proof to wake the egg and unlock a hatchable treat. Where did the egg go?
|
7b09f12 to
e49d1f2
Compare
e49d1f2 to
54fae1c
Compare
|
ClawSweeper applied the proposed close for this PR.
|
|
I could not reopen this PR from the contributor side after the maintainer/bot close; GitHub rejects both GraphQL and REST reopen attempts for #72501. I opened the current-main v2 replacement here instead: #95830 That new PR keeps the same #89573 scope but replaces the stale sidecar-era branch with the clean keyed-state implementation at head |




Problem
poll_answeris already declared inallowed-updates.ts, so Telegram delivers vote events to the bot, but no handler exists in the source. Vote events are silently dropped instead of reaching the agent session.Why it matters
Public polls sent via the
messagetool, oropenclaw message poll --poll-public, produce no agent wakeup when users vote. There is no way to build vote-responsive flows without this.Root cause
poll_answerwas added toallowed-updates.tswhen the poll send action was implemented, but the corresponding inbound routing handler was never added. Half-implemented feature.What changed
extensions/telegram/src/poll-registry.ts, new module storingpollId -> { chatId, question, options }usingwriteJsonAtomic, versioned schema, capped at 100 entries, per-account registry filesextensions/telegram/src/bot-handlers.runtime.ts,bot.on('poll_answer', ...)handler that looks up the registry, builds human-readable vote text, and routes into the session viaenqueueSystemEventextensions/telegram/src/action-runtime.ts, records poll registry entry on poll send, non-fatal if registry write failsextensions/telegram/src/allowed-updates.ts, addspoll_answerto allowed updatesWhat did NOT change
poll_answerfor anonymous pollsBehavior note
Only activates for non-anonymous, public polls,
pollPublic: trueor--poll-public. This is a Telegram API constraint.Security impact
Adds a new inbound event handler for updates Telegram was already delivering per
allowed-updates.ts. No new surface exposed. Voter identity comes from Telegram's authenticated update payload.Test plan
poll-registry.test.ts, store, retrieve, prune at 100 entriesbot.test.ts, routes vote into session, ignores missing registry entry gracefullyaction-runtime.test.ts, registry written on poll sendopenclaw message poll --poll-public, vote, confirm agent session receives wakeupPrior art
AI disclosure
Implementation drafted with AI assistance, OpenClaw agent 🦞.
Real behavior proof
poll_answer) now route into the originating Telegram session instead of being silently dropped.4a46756dc2, patched Telegram extension source, temporaryOPENCLAW_STATE_DIR.$ node scripts/test-projects.mjs extensions/telegram/src/poll-registry.test.ts extensions/telegram/src/action-runtime.test.ts extensions/telegram/src/bot.test.tsTelegram poll vote: "Ready?" — Ada Lovelace (@ada) voted: No. The send path also persisted the poll registry entry, and missing registry entries were ignored gracefully.mantis: telegram-visible-prooflabel for maintainer-run visible proof if required.