Commit Graph

422 Commits

Author SHA1 Message Date
Peter Steinberger 3bb02d3338
fix(media): align outbound sends with fs read capability 2026-04-01 00:07:50 +09:00
Peter Steinberger ac6f025c43
refactor(approvals): share telegram account binding 2026-03-31 15:39:59 +01:00
Vincent Koc 983891a603 fix(ci): narrow telegram route test seams 2026-03-31 23:37:18 +09:00
Peter Steinberger 461a3a4052
refactor(approvals): share request filter matching 2026-03-31 15:32:49 +01:00
Vincent Koc 7c4bffdecd fix(ci): rebalance telegram dm thread tests 2026-03-31 23:32:15 +09:00
Peter Steinberger c75f4695b7
refactor: move tasks into bundled plugin 2026-03-31 15:22:08 +01:00
Vincent Koc 6936033e98 test(telegram): stop overriding message-context session mocks 2026-03-31 23:01:21 +09:00
Vincent Koc aaf6077f27 test(telegram): skip session persistence in message-context harness 2026-03-31 22:51:25 +09:00
Vincent Koc 3be08454f4 test(telegram): narrow resolve-media retry imports 2026-03-31 22:45:39 +09:00
Vincent Koc 91115cdf61 test(telegram): stub menu sync in command harness 2026-03-31 22:31:12 +09:00
Vincent Koc 2df86cce1c refactor(telegram): narrow native command reply dispatch seam 2026-03-31 22:28:53 +09:00
Vincent Koc ff36bc314d test(telegram): use shared delivery mock in registry test 2026-03-31 22:18:29 +09:00
Vincent Koc 7710579a82 perf(telegram): narrow native command import surface 2026-03-31 21:43:16 +09:00
Vincent Koc b19e28a85e fix(telegram): lazy-load sticker vision model lookup 2026-03-31 21:31:05 +09:00
Vincent Koc e6441760d2 test(telegram): normalize message-context timing inputs 2026-03-31 21:10:43 +09:00
Vincent Koc 334085fbe9 test(channels): inject telegram reply pipeline for dispatch tests 2026-03-31 20:54:30 +09:00
Vincent Koc 1243e2c0b6 fix(telegram): keep test harness CJS-safe 2026-03-31 20:04:21 +09:00
Vincent Koc cf3ae2612b fix(ci): reduce slow channel test skew 2026-03-31 19:49:40 +09:00
Vincent Koc 8dfbcaa200 fix(ci): default local low-memory checks 2026-03-31 15:05:04 +09:00
Gabriel M. f7ced438f7
fix: restore Telegram forum-topic routing (#56060) (thanks @one27001)
* feat(telegram): add child thread-binding placement via createForumTopic

Enable ACP subagent spawn on Telegram by adding "child" placement
support to the thread-bindings adapter. When a child binding is
requested, the adapter creates a new forum topic via the Telegram
Bot API and binds the subagent session to it using the canonical
chatId:topic:topicId conversation ID format.

When the ACP spawn context provides only a topic ID (not a full
group chat ID), the adapter resolves the group from the configured
Telegram groups in openclaw.json.

This mirrors the Discord adapter's child placement behavior
(thread creation + session binding) and unblocks the orchestrator
pattern on Telegram forum-enabled groups.

Closes #5737
Ref #23414

* fix(telegram): return null with warning instead of silent group fallback for bare topic IDs in child bind

* telegram: fix ACP child thread spawn with group chat ID from agentGroupId

* telegram: scope agentGroupId substitution to telegram channel only

* Telegram: fix forum topic replies routing to root chat instead of topic thread

* fix: clean up dead guard in child bind + add explicit threadId override test

- Simplify bare-topic-ID guards in thread-bindings.ts: split into
  separate !chatId and !chatId.startsWith("-") checks, removing
  unreachable second condition
- Add regression test confirming explicit turnSourceThreadId overrides
  session lastThreadId on same channel

* fix: guard threadId fallback against shared-session race

Codex review P1: when turnSourceTo differs from the session's stored
to, the session threadId may belong to a different chat/topic. Only
fall back to context.threadId when the destination also matches.

* fix(telegram): enable ACP spawn from forum topics without thread binding

extractExplicitGroupId returned topic-qualified IDs (-100...:topic:1264)
instead of bare group chat IDs, breaking agentGroupId resolution.
agentGroupId was also never wired in the inline actions path.

For Telegram forum topics, skip thread binding entirely — the delivery
plan already routes correctly via requester origin (to + threadId).
Creating new forum topics per child session is unnecessary; output goes
back to the same topic the user asked from.

* fix(acp): bind Telegram forum sessions to current topic

* fix: restore Telegram forum-topic routing (#56060) (thanks @one27001)

---------

Co-authored-by: openclaw <mgabrie.dev@gmail.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-31 10:18:09 +05:30
ToToKr e89bd883d8
fix: allow Telegram RFC2544 media downloads (#57624) (thanks @MoerAI)
* fix(telegram): allow RFC 2544 benchmark IPs in media download SSRF policy (#57452)

Telegram CDN file servers may resolve to IPs in the RFC 2544 benchmark range (198.18.0.0/15). The SSRF policy blocked these downloads while Discord and Slack correctly allowed them. Set allowRfc2544BenchmarkRange to true to match other channel plugins.

* fix: note Telegram media RFC2544 CDN downloads (#57624) (thanks @MoerAI)

---------

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-03-31 09:53:31 +05:30
Peter Steinberger f7285e0a9e
test: speed up extension suites 2026-03-31 02:25:02 +01:00
scoootscooob 9ff57ac479
refactor(exec): unify channel approvals and restore routing/auth (#57838)
* fix(exec): add shared approval runtime

* fix(exec): harden shared approval runtime

* fix(exec): guard approval expiration callbacks

* fix(exec): handle approval runtime races

* fix(exec): clean up failed approval deliveries

* fix(exec): restore channel approval routing

* fix(exec): scope telegram legacy approval fallback

* refactor(exec): centralize native approval delivery

* fix(exec): harden approval auth and account routing

* test(exec): align telegram approval auth assertions

* fix(exec): align approval rebase followups

* fix(exec): clarify plugin approval not-found errors

* fix(exec): fall back to session-bound telegram accounts

* fix(exec): detect structured telegram approval misses

* test(exec): align discord approval auth coverage

* fix(exec): ignore discord dm origin channel routes

* fix(telegram): skip self-authored message echoes

* fix(exec): keep implicit approval auth non-explicit
2026-03-30 15:49:02 -07:00
Shakker 3ad747e25f style: apply formatter cleanups 2026-03-30 16:20:27 +01:00
pgondhi987 c4fa8635d0
fix(telegram): gate audio preflight transcription on sender authorization (#57566)
* Telegram: gate audio preflight transcription on sender authorization

* fix: honor telegram audio preflight command auth
2026-03-30 12:19:31 +01:00
Gustavo Madeira Santana 8b0cbebe43
Telegram: align channel test with runtime probe precedence 2026-03-29 23:34:03 -04:00
Gustavo Madeira Santana f380305ee4
Tests: restore extension plugin test seams 2026-03-29 22:38:44 -04:00
Peter Steinberger 9d005e6fbb
fix: stabilize telegram contract runtime coverage 2026-03-30 03:02:25 +01:00
Gustavo Madeira Santana acea28a9bb
Telegram: fix extension-fast test seams 2026-03-29 21:54:47 -04:00
Gustavo Madeira Santana f44174cf61
Extensions: stabilize telegram registry contracts 2026-03-29 21:42:58 -04:00
Peter Steinberger fec51572a3
fix: stabilize gate and extension boundary checks 2026-03-30 02:37:36 +01:00
Vincent Koc 3034adfdb3 fix(commands): harden fast status and Telegram callbacks 2026-03-30 09:32:53 +09:00
Vincent Koc b82fd50472 fix(test): add extension-safe test helper bridges 2026-03-30 09:31:33 +09:00
Peter Steinberger 63cbc097b5
refactor(channels): route core through registered plugin capabilities 2026-03-30 01:03:42 +01:00
Peter Steinberger 3b878e6b86
refactor: move approval auth and payload hooks to generic channel capabilities 2026-03-30 08:46:44 +09:00
Peter Steinberger 8720070fe0
refactor: rename channel approval capabilities 2026-03-30 08:28:33 +09:00
Peter Steinberger 52fb4a149a
refactor: share approval interactive renderers 2026-03-30 08:03:59 +09:00
Peter Steinberger cfac0e8698
refactor: move plugin-owned test support into plugins 2026-03-30 08:03:04 +09:00
Peter Steinberger 8861cdbb6f
refactor(plugin-sdk): untangle extension test seams 2026-03-29 23:43:53 +01:00
Peter Steinberger 69eea2cb80
refactor: split approval auth delivery and rendering 2026-03-30 07:36:18 +09:00
Peter Steinberger f8dc4305a5
refactor: share native approval delivery helpers 2026-03-30 07:16:33 +09:00
Peter Steinberger 6d9a7224aa
refactor: unify approval command authorization 2026-03-30 07:06:29 +09:00
Peter Steinberger 3ec000b995
refactor: align same-chat approval routing 2026-03-30 06:52:28 +09:00
Peter Steinberger 574d3c5213
fix: make same-chat approvals work across channels 2026-03-30 06:35:04 +09:00
Peter Steinberger 1ca01b738b
fix: stabilize exec approval approver routing 2026-03-30 06:25:03 +09:00
Peter Steinberger cce6d3bbb7
fix: resolve CI type and lint regressions 2026-03-30 04:51:33 +09:00
Peter Steinberger 855878b4f0
fix: stabilize serial test suite 2026-03-30 04:46:04 +09:00
Peter Steinberger 8109195ad8
fix(plugin-sdk): avoid recursive bundled facade loads 2026-03-29 15:00:25 +01:00
Peter Steinberger 270d0c5158
fix: avoid telegram plugin self-recursive sdk imports 2026-03-29 11:32:29 +01:00
Peter Steinberger 8e0ab35b0e
refactor(plugins): decouple bundled plugin runtime loading 2026-03-29 09:10:38 +01:00