Guard Telegram runtime progress and report delivery#80021
Guard Telegram runtime progress and report delivery#80021baragozhelper-ux wants to merge 3 commits into
Conversation
|
Codex review: needs real behavior proof before merge. Summary Reproducibility: yes. Source inspection is enough to reproduce the introduced failure modes: the PR calls guard checks before delivery can fail, while current main shows Real behavior proof Next step before merge Security Review findings
Review detailsBest possible solution: Keep the guard Telegram-owned at the final delivery boundary, but commit dedupe only after successful sends, preserve the existing progress renderer/configuration, and scope media dedupe to real report artifacts with focused tests plus redacted live proof. Do we have a high-confidence way to reproduce the issue? Yes. Source inspection is enough to reproduce the introduced failure modes: the PR calls guard checks before delivery can fail, while current main shows Is this the best way to solve the issue? No. Moving suppression to Telegram delivery boundaries is reasonable, but this implementation is not the best fix because it records dedupe before successful delivery, hard-codes progress text, and over-dedupes local media. Full review comments:
Overall correctness: patch is incorrect What I checked:
Likely related people:
Remaining risk / open question:
Codex review notes: model gpt-5.5, reasoning high; reviewed against fa0506bd3185. |
|
Closing this draft as superseded by merged #80075. The #80021 branch addressed the visible Telegram delivery-boundary symptom, but #80075 fixes the higher-level embedded payload selection root cause so accumulated assistantTexts no longer become multiple channel-visible final replies. I will not continue the downstream guard branch. If any residual Telegram leak reproduces on current main after #80075, I will open a new narrow residual PR from main with focused reproduction and proof. |
Summary
Updates the durable Telegram runtime communications guard so visible service/process leaks are blocked both at the direct Telegram send helper and at the automatic Telegram reply delivery path.
Changes
sendMessageTelegram, the direct Telegram API delivery helper.deliverReplies, the automatic assistant reply path used for normal Telegram replies.task_store.MODEL-GATEtask_type:/risk_level:/proceed_status:Gateway restart ...Reason:/Run:restart hintsopenclaw doctorWorking....mdartifact can be delivered without leakingMODEL-GATEas caption text.Идет работа.) deduped and allowed once.Verification
npm test -- --run extensions/telegram/src/bot/delivery.test.ts extensions/telegram/src/send.test.ts extensions/telegram/src/outbound-adapter.test.tsnpm run lint:extensions -- extensions/telegram/src/runtime-comms-guard.ts extensions/telegram/src/send.ts extensions/telegram/src/send.test.ts extensions/telegram/src/send.test-harness.ts extensions/telegram/src/bot/delivery.replies.ts extensions/telegram/src/bot/delivery.test.ts extensions/telegram/src/outbound-adapter.ts extensions/telegram/src/outbound-adapter.test.tsRegression coverage
Adds tests for the real adaptation scenario:
MODEL-GATE;.mdfile is delivered immediately;MODEL-GATEis not sent as text or media caption;Notes
This remains a draft PR for review. It does not change upstream
mainunless it is accepted and merged.