Commit Graph

312 Commits

Author SHA1 Message Date
Vincent Koc 783cbd1e9d fix(ci): refresh plugin sdk baseline and formatting 2026-03-24 11:45:37 -07:00
Bob 7fab2c2897
fix(discord): notify user on discord when inbound worker times out (#53823)
* fix(discord): notify user on discord when inbound worker times out.

* fix(discord): notify user on discord when inbound worker times out.

* Discord: await timeout fallback reply

* Discord: add changelog for timeout reply fix (#53823) (thanks @Kimbo7870)

---------

Co-authored-by: VioGarden <111024100+VioGarden@users.noreply.github.com>
Co-authored-by: Onur Solmaz <2453968+osolmaz@users.noreply.github.com>
2026-03-24 19:01:12 +01:00
Peter Steinberger 5edba12f79 test: speed up discord slack telegram suites 2026-03-24 16:26:58 +00:00
Tak Hoffman 3e9ff16645
fix(discord): avoid bundling pi-ai runtime deps 2026-03-24 11:17:08 -05:00
Peter Steinberger 1d4db9920d test: speed up discord extension suites 2026-03-24 15:57:16 +00:00
Peter Steinberger 781295c14b refactor: dedupe test and script helpers 2026-03-24 15:48:35 +00:00
David Guttman aa91000a5d
feat(discord): add autoThreadName 'generated' strategy (#43366)
* feat(discord): add autoThreadName 'generated' strategy

Adds async thread title generation for auto-created threads:
- autoThread: boolean - enables/disables auto-threading
- autoThreadName: 'message' | 'generated' - naming strategy
- 'generated' uses LLM to create concise 3-6 word titles
- Includes channel name/description context for better titles
- 10s timeout with graceful fallback

* Discord: support non-key auth for generated thread titles

* Discord: skip fallback auto-thread rename

* Discord: normalize generated thread title first content line

* Discord: split thread title generation helpers

* Discord: tidy thread title generation constants and order

* Discord: use runtime fallback model resolution for thread titles

* Discord: resolve thread-title model aliases

* Discord: fallback thread-title model selection to runtime defaults

* Agents: centralize simple completion runtime

* fix(discord): pass apiKey to complete() for thread title generation

The setRuntimeApiKey approach only works for full agent runs that use
authStorage.getApiKey(). The pi-ai complete() function expects apiKey
directly in options or falls back to env vars — it doesn't read from
authStorage.runtimeOverrides.

Fixes thread title generation for Claude/Anthropic users.

* fix(agents): return exchanged Copilot token from prepareSimpleCompletionModel

The recent thread-title fix (3346ba6) passes prepared.auth.apiKey to
complete(). For github-copilot, this was still the raw GitHub token
rather than the exchanged runtime token, causing auth failures.

Now setRuntimeApiKeyForCompletion returns the resolved token and
prepareSimpleCompletionModel includes it in auth.apiKey, so both the
authStorage path and direct apiKey pass-through work correctly.

* fix(agents): catch auth lookup exceptions in completion model prep

getApiKeyForModel can throw for credential issues (missing profile, etc).
Wrap in try/catch to return { error } for fail-soft handling rather than
propagating rejected promises to callers like thread title generation.

* Discord: strip markdown wrappers from generated thread titles

* Discord/agents: align thread-title model and local no-auth completion headers

* Tests: import fresh modules for mocked thread-title/simple-completion suites

* Agents: apply exchanged Copilot baseUrl in simple completions

* Discord: route thread runtime imports through plugin SDK

* Lockfile: add Discord pi-ai runtime dependency

* Lockfile: regenerate Discord pi-ai runtime dependency entries

* Agents: use published Copilot token runtime module

* Discord: refresh config baseline and lockfile

* Tests: split extension runs by isolation

* Discord: add changelog for generated thread titles (#43366) (thanks @davidguttman)

---------

Co-authored-by: Onur Solmaz <onur@textcortex.com>
Co-authored-by: Onur Solmaz <2453968+osolmaz@users.noreply.github.com>
2026-03-24 16:27:19 +01:00
Peter Steinberger 88f49c27a0 test: speed up discord extension suites 2026-03-24 15:16:18 +00:00
Vincent Koc 29ad211e76
fix(plugins): unblock Discord/Slack message tool sends and Feishu media (#52991)
* fix(plugins): unblock Discord and Slack message tool payloads

* docs(changelog): note Discord Slack and Feishu message fixes
2026-03-23 09:04:57 -07:00
Peter Steinberger b393effba6 test: harden channel suite isolation 2026-03-23 12:57:43 +00:00
Peter Steinberger fc9739313c test: harden channel suite isolation 2026-03-23 11:09:12 +00:00
Peter Steinberger abf2157b18
fix: sync agent and autoreply e2e updates 2026-03-23 01:33:40 -07:00
Peter Steinberger 5f05c92922
test: harden no-isolate reply teardown 2026-03-23 00:37:32 -07:00
Peter Steinberger 6b9915a106
refactor!: drop legacy CLAWDBOT env compatibility 2026-03-22 22:13:39 -07:00
Vincent Koc 1354f37c88
fix(plugins): route keyed queue imports through core (#52608) 2026-03-22 20:35:28 -07:00
Peter Steinberger 5c8ea0a175 refactor: share channel setup status helpers 2026-03-23 01:56:01 +00:00
Vincent Koc a61e5d17f0
deps: update fast-xml-parser and markdown-it (#52541)
* style: format test files

* deps: bump fast-xml-parser override
2026-03-22 17:55:47 -07:00
Vincent Koc 0743368013 fix(test): split discord monitor agent components 2026-03-22 17:54:52 -07:00
Vincent Koc a8b9763d66 fix(test): split discord monitor utility coverage 2026-03-22 17:47:45 -07:00
Vincent Koc b21bcf6eb6 fix(test): reduce channel suite startup hotspots 2026-03-22 17:36:32 -07:00
Peter Steinberger 80e9737db4 test: align discord action expectation 2026-03-22 23:54:52 +00:00
Peter Steinberger 72bfaf6ee2 refactor: share computed channel status adapters 2026-03-22 23:37:12 +00:00
Peter Steinberger 4cc0d05cfb refactor: share channel runtime state defaults 2026-03-22 23:37:12 +00:00
Peter Steinberger d73852ff21 fix: land plugin discovery missing-entry handling (#52491) (thanks @hclsys) 2026-03-22 23:22:48 +00:00
Peter Steinberger e0af23106c ci: fix workflow sanity gate 2026-03-22 23:04:04 +00:00
Vincent Koc 59be2c8679 test(discord): cover additional utility surfaces 2026-03-22 15:55:41 -07:00
Vincent Koc 82508e3931 test(extensions): add discord and telegram coverage 2026-03-22 15:55:41 -07:00
scoootscooob 24032dcc0e
Reply: fix generated image delivery to Discord (#52489) 2026-03-22 15:18:16 -07:00
Peter Steinberger f1975c0c0a refactor: adopt chat plugin builder in discord 2026-03-22 22:00:25 +00:00
Peter Steinberger af4f2a8028 fix(discord): ignore empty components on media send 2026-03-22 21:45:36 +00:00
Peter Steinberger 87b2672126 refactor: centralize computed channel status adapters 2026-03-22 21:37:31 +00:00
Peter Steinberger 87722d6327 refactor: extend shared account status snapshot helpers 2026-03-22 20:55:16 +00:00
Peter Steinberger 00b2f10dec refactor: share account snapshot descriptions 2026-03-22 20:55:16 +00:00
Peter Steinberger 7a2709c391 refactor: simplify channel allowlist resolvers 2026-03-22 20:30:21 +00:00
Peter Steinberger fa13c2960e refactor: share scoped account accessor adapters 2026-03-22 20:30:21 +00:00
Peter Steinberger 6fa0027c61 refactor: simplify tlon and discord setup accounts 2026-03-22 19:53:51 +00:00
Vincent Koc 9bb5eb6c7f fix(test): repair channel regression suites 2026-03-22 12:51:36 -07:00
Peter Steinberger bd108dfe00 test: fix CI contract drift in channel suites 2026-03-22 19:44:10 +00:00
Vincent Koc 5f723ecd7f
fix(doctor): explain discord streaming opt-in (#52450) 2026-03-22 12:37:03 -07:00
Peter Steinberger c74a50e4f1 refactor: share merged account config helper 2026-03-22 19:01:52 +00:00
Peter Steinberger ff759f991e refactor: share account config merge helper 2026-03-22 19:01:52 +00:00
Peter Steinberger 7ae09410b7 refactor: reuse shared account config lookups 2026-03-22 19:01:52 +00:00
Peter Steinberger 412a3eb1ac
build: bump version to 2026.3.22 2026-03-22 11:58:33 -07:00
Peter Steinberger 2c919078e1 refactor: share memory and discord singleton state 2026-03-22 18:09:45 +00:00
Peter Steinberger 89d65521fe refactor: dedupe extension runtime caches 2026-03-22 18:09:45 +00:00
Peter Steinberger 8a111f1cb9 test: harden discord monitor regression assertions 2026-03-22 16:56:44 +00:00
Peter Steinberger b0176f626c test: tighten discord model picker regressions 2026-03-22 16:56:41 +00:00
Peter Steinberger 68170f99ac test: tighten discord monitor regression assertions 2026-03-22 16:49:16 +00:00
Peter Steinberger a94ec3b79b
fix(security): harden exec approval boundaries 2026-03-22 09:35:25 -07:00
Peter Steinberger 3fa2300ba1 perf: reduce plugin runtime startup overhead 2026-03-22 16:34:09 +00:00