fix(telegram): resolve DM topic thread ids#80726
Conversation
|
Codex review: found issues before merge. Reviewed July 3, 2026, 11:50 PM ET / 03:50 UTC. Summary PR surface: Source +23, Tests +37. Total +60 across 7 files. Reproducibility: yes. by source inspection: current main reads only Review metrics: none identified. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Mantis proof suggestion Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Land a refreshed Telegram plugin fix that adds the inbound DM-topic fallback across context, native commands, runtime routing, and sequential keys while preserving forum-topic and outbound direct-topic semantics. Do we have a high-confidence way to reproduce the issue? Yes by source inspection: current main reads only Is this the best way to solve the issue? Yes after refresh: a Telegram-local resolver is the narrow owner-boundary fix, but the branch must first be reconciled with current main without merging outbound Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 9d68f877ac3e. Label changesLabel justifications:
Evidence reviewedPR surface: Source +23, Tests +37. Total +60 across 7 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
|
|
Added real Telegram behavior proof for this change. Verified against a BotFather Threaded Mode private chat with OpenClaw configured for inbound topic/session isolation:
Private chat/user/topic details are redacted, but this matches the failure mode this PR fixes. Local verification also covered:
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
@openclaw-mantis telegram desktop proof: verify Telegram DM topic thread routing. Show that messages in BotFather Threaded Mode/private DM topics route to the correct topic/session instead of losing or misrouting the thread id. |
Mantis Telegram Desktop ProofSummary: Mantis skipped Telegram Desktop before/after GIF proof because this PR did not have an honest native Telegram-visible before/after.
|
|
Added redacted Telegram Desktop proof for BotFather Threaded Mode DM-topic behavior. Evidence:
These screenshots show OpenClaw replies remaining inside separate Telegram DM topics instead of collapsing into the flat This matches the PR's target behavior: inbound DM-topic messages resolve to the originating topic/thread id, and outbound replies are rendered by Telegram in that same topic. Private chat/user details are redacted. @clawsweeper re-review |
|
ClawSweeper PR egg ✨ Hatched: 💎 rare Cosmic Test Hopper Hatch commandComment Hatchability rules:
Rarity: 💎 rare. What is this egg doing here?
|
|
This pull request has been automatically marked as stale due to inactivity. |
|
ClawSweeper status: review started. I am starting a fresh review of this pull request: fix(telegram): resolve DM topic thread ids This is item 1/1 in the current shard. Shard 16/22. This placeholder means the worker is alive and reading the current context. I will edit this same comment with the actual review when the claws are done clicking. Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted. |


Summary
message_thread_idor Bot APIdirect_messages_topic.topic_idTesting
OPENCLAW_VITEST_INCLUDE_FILE=/tmp/openclaw-vitest-include.json OPENCLAW_VITEST_MAX_WORKERS=1 corepack pnpm vitest run --config test/vitest/vitest.extension-telegram.config.ts --typecheck --reporter verboseOPENCLAW_VITEST_INCLUDE_FILE=/tmp/openclaw-vitest-include-2.json OPENCLAW_VITEST_MAX_WORKERS=1 corepack pnpm vitest run --config test/vitest/vitest.extension-telegram.config.ts --typecheck --reporter dotcorepack pnpm format:check extensions/telegram/src/bot/helpers.ts extensions/telegram/src/bot/helpers.test.ts extensions/telegram/src/bot-message-context.ts extensions/telegram/src/bot-message-context.dm-topic-threadid.test.ts extensions/telegram/src/bot-native-commands.ts extensions/telegram/src/bot-handlers.runtime.ts extensions/telegram/src/sequential-key.tsgit diff --check