Commit Graph

1343 Commits

Author SHA1 Message Date
Peter Steinberger
9922ea02e9 fix(matrix): preserve media, reaction, and member state (#116890)
Co-authored-by: Peter Steinberger <steipete@macos.shared>
2026-07-31 08:08:32 -07:00
Peter Steinberger
f061b82d11 fix(matrix): preserve message-tool room thread routing (#116802)
Co-authored-by: Peter Steinberger <steipete@macos.shared>
2026-07-31 05:05:16 -07:00
joshavant
b7bfe21348 test(matrix): use preferred temp root 2026-07-30 16:07:51 -05:00
joshavant
7051d94f79 test(matrix): keep temp tracker plugin-local 2026-07-30 16:07:51 -05:00
joshavant
f36bfabf89 test(matrix): use temp directory tracker 2026-07-30 16:07:51 -05:00
Benjamin Badejo
ab24d29d6c fix(matrix): use managed SQLite opener 2026-07-30 16:07:51 -05:00
Benjamin Badejo
aa8fbb7f3c fix(matrix): reserve dedupe migration capacity 2026-07-30 16:07:51 -05:00
Benjamin Badejo
505d7b9f52 fix(state): preserve doctor import TTL 2026-07-30 16:07:51 -05:00
Benjamin Badejo
d25e89d1ee fix(matrix): preserve migrated dedupe retention order 2026-07-30 16:07:51 -05:00
Benjamin Badejo
d140a051ce chore(matrix): keep census result type private 2026-07-30 16:07:51 -05:00
Benjamin Badejo
080cbb1693 fix(matrix): fail closed on incomplete dedupe census 2026-07-30 16:07:51 -05:00
Benjamin Badejo
cb95f6e9e8 fix(matrix): checkpoint completed dedupe migration 2026-07-30 16:07:51 -05:00
Benjamin Badejo
8155f64b64 fix(matrix): migrate dedupe from legacy state databases 2026-07-30 16:07:51 -05:00
pash-openai
e52354ea13 fix(build): pin typebox to a published release (#116333) 2026-07-30 09:58:51 +00:00
Ayaan Zaidi
21d3533460 fix(channels): ack mentions in groups that do not require them
The group-mentions ack gate returned false whenever a group did not require mentions, conflating group policy with whether this message mentioned the agent. Under the default scope, mentioning the agent in a group configured to answer everything produced no ack at all, so the user had no signal the turn was picked up until the reply arrived.

Behavior change on a default path: those groups now show the 👀 ack (and the lifecycle status reactions when messages.statusReactions.enabled is true) on mentions. Mention-required groups, group-all, unmentioned messages, and off/none are unchanged. The gate no longer reads requireMention, so the parameter is gone from the shared type and all channel call sites.

Proven live on Telegram across three configurations, including a no-mention control confirming group-mentions did not become group-all.
2026-07-30 17:58:46 +09:00
joshavant
32a61cabf0 fix(matrix): observe automatic reply settlement 2026-07-30 02:31:15 -05:00
Ayaan Zaidi
06aa81a73f fix(channels): show tool lines under the progress status headline
A status headline replaced the rolling tool lines instead of sitting above
them, so a default Discord draft showed one preamble sentence for an entire
tool-heavy turn. Operators reached for `/verbose` to see any activity, which
delivers durable per-tool-call messages and floods the channel.

- Render the headline above the lines; both stay visible in one message.
- Shorten the start gate from 5s to 1.5s. The gate only creates the draft
  when the timer fires and finalize cancels it, so quick answers still post
  no draft while a 3s tool turn stops being silent.
- Drop Discord's label-gated tool-progress default so
  resolveChannelStreamingPreviewToolProgress is the single owner. An explicit
  `toolProgress: false` still silences the lines.
- Resolve that toggle against a "progress" mode guess when `streaming.mode`
  is unset, so the progress-draft channels stop ignoring an explicit
  `progress.toolProgress` opt-out.

Telegram now defaults to `streaming.mode: "progress"` like Discord; set
`"partial"` to keep streamed answer text. Its renderer draws work lines from
the compositor's structured lines, so `rendersRollingLinesNatively` keeps
them out of the composed text rather than printing every line twice.
2026-07-30 13:36:21 +09:00
Peter Steinberger
d16e33e08e fix: restore trustworthy end-to-end QA and cross-channel delivery (#115404)
* fix(qa): repair verified end-to-end and channel regressions

* fix(gateway): make interrupted restart recovery lifecycle-safe

* test(heartbeat): target the canonical recovery session store

* fix(gateway): prioritize durable restart recovery before heartbeat

* fix(qa): preserve safe restart recovery and channel expiry

* fix(qa): fail closed and fence restart recovery

* test(agents): isolate restart recovery timing

* test(agents): prove actual restart retry timing

* fix(qa): report incompatible profile scenarios

* fix(scripts): resolve symlinked docker scheduler entrypoints

* fix(qa): require fresh native test evidence

* fix(heartbeat): fence active restart recovery delivery

* fix(gateway): consume untargeted restart acknowledgements

* fix(qa): satisfy exhaustive hosted validation gates

* fix(agents): fence stopped restart recovery dispatch

* style(agents): format restart recovery lifecycle regression

* test(gateway): isolate context prewarm sidecar lifecycle

* test(qa): make scenario process timeout cleanup deterministic

* fix(qa): stamp synthetic gateway configs with current version

* fix(openai): preserve vision capabilities in stale model catalogs

* test(qa): align profile channel rejection with current main

* fix(openai): forward supported moderation for image edits

* fix: restore latest-main CI and image edit documentation

* fix(qa): retain relocated code-mode evidence validation

* fix(openai): expose GPT-5.4 vision in static catalog

* fix(pricing): honor explicit model cost overrides

* test(pricing): keep isolated provider regressions deterministic

* fix(openai): inherit transport for discovered static models

* fix(gateway): honor agent-owned static image capabilities

* test(gateway): preserve prepared-snapshot attachment races

* test(gateway): isolate subagent persistence failure injection

* test(gateway): exercise concurrent voice replay admission

* fix(gateway): restore stale model image capabilities

* fix(agents): publish configured model vision capabilities

* fix(agents): isolate detached media transcript ownership

* test(agents): preserve generic transcript lock regression

* fix(gateway): require proven static model route identity

* fix(qa): accept bounded full-size generated image attachments

* fix(qa): require fresh script producer evidence

* test(qa): prove native E2E scenario execution
2026-07-29 12:45:27 -04:00
Peter Steinberger
5bfc65d7f4 refactor: remove 3,543 lines of redundant runtime and tests (#115961)
* refactor: remove 3,543 lines of redundant runtime and tests

* refactor: ratchet production environment variable budget
2026-07-29 11:43:41 -04:00
Peter Steinberger
4232126bba chore: update dependencies across workspace (#115677)
* chore(deps): update dependencies

* fix(deps): restore CI compatibility
2026-07-29 05:16:42 -04:00
Peter Steinberger
c402688894 feat(media): probe duration and dimensions for playback metadata (#115728)
* feat(media): probe playback metadata

* fix(media): satisfy CI gates

* fix(media): satisfy lint rules
2026-07-29 04:52:17 -04:00
Peter Steinberger
d37fd8f2d4 fix(matrix): accept documented automatic approval mode (#115676)
Restore the explicitly shipped Matrix approval mode without changing omitted, boolean, invalid, or non-strict configuration behavior. Regenerate the canonical channel metadata and prove native Matrix approvals against a real homeserver.

Co-authored-by: mingdideng <deng.mingdi@xydigit.com>
2026-07-29 03:37:19 -04:00
Peter Steinberger
dbe645a08f fix(matrix): prevent private reasoning from reaching rooms (#99412) (#115553) 2026-07-29 00:55:07 -04:00
joshavant
ba85271dbe fix(matrix): suppress previews for modifying hooks 2026-07-28 11:47:49 -05:00
chengzhichao-xydt
dcce5b5237 fix(matrix): honor abortSignal during startup whoami retry backoff (#110115)
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-28 08:13:09 -04:00
Wynne668
1d047ac4f1 fix(matrix): reject non-canonical synthetic thread cursors (#111243) 2026-07-28 06:40:11 -04:00
Peter Steinberger
c9b0f4260f fix(matrix): render message history and collapse streamed edits (#115014)
Fixes #101420. Preserve Matrix-native JSON fields while projecting readable message and pin tables. Apply only valid same-sender edits, honor homeserver replacement aggregates, and preserve cross-page updates, redactions, and original thread relationships.
2026-07-28 05:01:37 -04:00
Papilionidae
0680dfc6a9 fix(matrix): reverse-proxy path support for Matrix homeserver URLs (#93516)
* feat(matrix): add configurable apiPrefix for non-standard homeserver API paths

* fix(matrix): remove public apiPrefix config, keep transport path fix

The apiPrefix config surface was incomplete: it was not carried through
resolveMatrixConfigForAccount, MatrixAuth, shared client keying, or
createMatrixClient, making it a no-op in normal runtime paths.

Following ClawSweeper review direction, this narrow fix:
- Removes apiPrefix from MatrixConfigSchema and MatrixConfig types
- Keeps apiPrefix as a private internal constant in MatrixAuthedHttpClient
  for bare-path resolution (DEFAULT_API_PREFIX = /_matrix/client/v3)
- Stops MatrixClient from accepting/passing apiPrefix
- Retains the transport.ts normalizeEndpoint() fix for homeserver URLs
  behind reverse proxies (avoids losing path segments on trailing-slash
  mismatches)

Test: 1393 tests pass across 121 matrix extension test files.

* fix(matrix): ensure homeserver URL ends with slash for new URL() resolution

Without a trailing slash, new URL(relPath, homeserver) treats the final
path segment as a filename, losing the reverse-proxy prefix path.

For example:
  new URL('_matrix/...', 'https://host/proxy')
  -> https://host/_matrix/... (wrong, 'proxy' dropped)

With trailing slash:
  new URL('_matrix/...', 'https://host/proxy/')
  -> https://host/proxy/_matrix/... (correct)

* test(matrix): add URL resolution coverage for path-prefixed homeservers

* fix(matrix): preserve reverse-proxy homeserver paths

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-27 05:25:58 -04:00
Peter Steinberger
f6131a4fbf build(deps): remove npm shrinkwrap; mirror pnpm lock into transient package locks (#114006)
* build(deps): remove npm shrinkwrap; mirror pnpm lock into transient package locks

npm 12 removed shrinkwrap (command + tarball/root loading). Delete all 82
committed npm-shrinkwrap.json files and stop publishing lockfiles; keep
pnpm-lock.yaml as the single reviewed dependency boundary. The generator
becomes scripts/generate-npm-package-lock.mjs and feeds plugin bundling via
a transient package-lock.json + npm ci (works on npm 11 and 12). Tarball
validation treats the published 2026.7.2 beta train as a shrinkwrap
transition; self-update npm detection now uses install topology instead of
the shipped shrinkwrap.

* fix(deps): repair lint, deadcode, and test-type lanes for the npm 12 migration

- sort integrity comparisons with an explicit comparator (oxlint)
- keep resolveBunGlobalNodeModules module-local (knip unused-export gate)
- model npm pack --json as npm<=11 array / npm 12 name-keyed object
- default calver destructuring in the tarball test fixture
2026-07-26 01:29:55 -04:00
Peter Steinberger
5402ef192d refactor(matrix): split SDK client responsibilities (#113815)
* refactor(matrix): split SDK client responsibilities

* fix(matrix): drop stale split imports

* fix(matrix): narrow initialized decrypt bridge
2026-07-25 14:59:35 -07:00
Peter Steinberger
4aa4ff7250 refactor(matrix): split CLI command groups (#113664)
* refactor(matrix): split CLI command groups

* refactor(matrix): keep CLI helpers private

* refactor(matrix): retain profile result type contract
2026-07-25 06:37:08 -07:00
苟文
2579e4a420 docs: fix incorrect CLI command in extension READMEs (#112057)
Replace non-existent 'openclaw plugin add' with the correct
'openclaw plugins install' command in 14 extension README files.

The CLI only registers 'openclaw plugins install' (src/cli/plugins-cli.ts),
and the previous command would fail for users following the docs.

Co-authored-by: hilbert <xuxiaojing@tojoy.com>
2026-07-25 05:50:13 -07:00
Vincent Koc
618f910377 refactor(matrix): share bounded cache insertion (#113636) 2026-07-25 19:43:58 +08:00
Vincent Koc
92188c9e5a refactor(matrix): use shared string normalization (#113627) 2026-07-25 19:26:25 +08:00
Peter Steinberger
c94746c924 fix: restore plugin bindings and macOS test stability (#113588)
* test(plugin-sdk): canonicalize memory fixture roots

* fix(channels): resolve plugin binding agent scope

* chore: defer release-owned changelog

* test(agents): retry session store fixture cleanup

* test(discord): cover configured plugin binding agent
2026-07-25 02:30:24 -07:00
Peter Steinberger
446816f751 test: table-drive followup scenarios, centralize sanitizer wiring, remove obsolete negatives (#113583)
* test(auto-reply): table-drive followup runner scenarios

* test(channels): centralize sanitizer wiring coverage

* test: remove obsolete negative coverage
2026-07-25 02:14:44 -07:00
Vincent Koc
e4d6170237 refactor(matrix): reuse shared error coercion (#113586) 2026-07-25 16:54:55 +08:00
Ben Badejo
c61111ba93 fix(matrix): gateway startup stalls after repeated token rotation (#113489)
* fix(matrix): avoid scanning settled storage roots

* test(matrix): prove unsettled root fallback

---------

Co-authored-by: Benjamin Badejo <ben@benbadejo.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-25 01:52:41 -07:00
Peter Steinberger
d2b6573690 refactor(channels): remove v2026.7.2-gated compat (flat streaming keys, group intro hint) (#113533)
* refactor(channels): remove flat streaming compat

maintainer-approved early removal of v2026.7.2-gated compat

* refactor(channels): remove group intro hint adapter

maintainer-approved early removal of v2026.7.2-gated compat

Plugin SDK surface baseline update is maintainer-approved for this intentional removal.
2026-07-25 01:09:25 -07:00
Peter Steinberger
a5d758e74b refactor(plugin-sdk): share channel DM policy setup (#113537) 2026-07-25 01:00:53 -07:00
Peter Steinberger
92a35b599a refactor: share channel probe runner (#113540) 2026-07-25 00:24:31 -07:00
Peter Steinberger
e87b3cea18 refactor(plugin-sdk): share doctor key-move builder (#113539) 2026-07-25 00:21:15 -07:00
Peter Steinberger
1e9d918037 feat(sdk): always persist media facts and ship facts-first replacements for legacy Media* surfaces (#113355)
* feat(sdk): always persist media facts and ship facts-first replacements for legacy Media* surfaces

PR 1 of the media legacy retirement program (audit-frozen, 4 PRs).

- Every media-bearing user turn now persists normalized __openclaw.media
  facts unconditionally while continuing to emit the legacy top-level
  Media* projection byte-identically (dual-write bridge; the conditional
  shouldPersistStructuredMediaEntries gate now always includes media).
- New replacement APIs, shipped before any removal: typed hook media
  facts (media[], originalMedia[], mediaStagingPending) on message
  events; {{AttachmentPath}}/{{AttachmentUrl}}/{{AttachmentContentType}}/
  {{AttachmentDir}}/{{AttachmentIndex}} template variables; focused
  openclaw/plugin-sdk/media-local-roots subpath split out of the
  deprecated agent-media-payload facade.
- Every legacy surface carries @deprecated naming its replacement, under
  one named compatibility record media-legacy-projection with the
  operator-approved removeAfter 2026-10-01 (two release trains; deletion
  additionally gates on a clean published-plugin artifact sweep).
- Generic transcript append invariant documented; SDK migration, hooks,
  and configuration docs updated to the facts-first path.

Writer golden matrix proves legacy bytes and model prompt bytes are
unchanged while nested facts become unconditional. 2,189 broad media
tests green; SDK api-baseline regenerated on fresh-env Testbox.

* feat(sdk): register media-local-roots subpath exports and deprecation metadata

Completes PR 1: package export map for openclaw/plugin-sdk/media-local-roots
plus the deprecated-subpath inventory and doc metadata entries for the
media-legacy-projection record.

* chore(sdk): track media-local-roots entrypoint and deprecated-export budgets

* fix(sdk): keep deprecated MSTeams buildMediaPayload re-export through the compat window

Deleting shipped runtime-api re-exports belongs to retirement PR 4 after
the media-legacy-projection window; PR 1 only deprecates. Also formats
the migration-guide schedule table.

* docs: regenerate docs map for media migration additions
2026-07-24 10:42:17 -07:00
Peter Steinberger
21f0cef5d5 refactor(matrix): split monitor handler pipeline (#113269)
* refactor(matrix): split monitor handler pipeline

* refactor(matrix): align extracted handler types

* refactor(matrix): make missing context explicit

* style(matrix): order extracted handler imports
2026-07-24 01:02:56 -07:00
Peter Steinberger
73bba03e4c refactor: canonicalize session delivery state (#113225)
* refactor: canonicalize session delivery state

* test: canonicalize reply persistence fixtures

* test: canonicalize talk delivery fixtures

* test: canonicalize voice session routes

* test: canonicalize attachment delivery fixtures

* test: migrate gateway delivery fixtures

* fix: skip invalid session delivery rows

* test: align delivery SDK surface gates

* fix: preserve legacy delivery precedence

* test: canonicalize heartbeat delivery fixtures

* fix: preserve delivery route prompt identity

* test: canonicalize session delivery fixtures

* fix: preserve recoverable legacy delivery routes

* fix: canonicalize remaining session state

* fix: preserve canonical session classification

* style: format delivery state changes

* test: refresh plugin SDK delivery baseline

* test: avoid mutating session fixture input

* style: simplify delivery identity check

* style: simplify delivery origin spread

* fix: preserve fresh delivery route metadata

* test: assert canonical surface route switch

* fix: canonicalize doctor file-store imports

* fix: preserve transitional delivery migration state

* fix: satisfy canonical delivery CI gates

* ci: scope GitHub App token permissions

* test: infer canonical delivery projections

* test: canonicalize ACP requester delivery fixtures

* test: canonicalize harness rollback fixture

* style: apply pinned formatter
2026-07-24 01:01:19 -07:00
Peter Steinberger
aae10cade5 refactor(markdown): unify format profile declarations (#113254)
* refactor(markdown): unify format profile declarations

* test(markdown): avoid suppression inventory drift
2026-07-24 00:37:59 -07:00
Peter Steinberger
21103ff8e9 feat(matrix): render spoilers, underline, and native tables (#113199)
* feat(matrix): add native markdown capabilities

* chore(matrix): remove stale runtime accessor

* chore(matrix): satisfy extension lint

* test(matrix): complete formatter runtime coverage
2026-07-23 19:05:38 -07:00
Peter Steinberger
acd92f6a3d chore(deps): refresh repository dependencies (#112453)
* build(deps): update QA broker dependency

* build(deps): refresh repository dependencies

* build(deps): reconcile rebased shrinkwraps

* test(plugins): remove stale loader test state

* test(deps): stabilize updated dependency coverage

* fix(swift): use caller-isolated TaskLocal overload

* build(deps): regenerate rebased shrinkwraps

* test(msteams): preserve DNS validation in fetch helper

* fix(deps): avoid vulnerable optional image stack

* test(deps): validate generated LRU override

* refactor(ui): extract chat resizable divider

* test(ui): update divider ownership path

* fix(matrix): retain restart-compatible SDK

* style(cron): format update test
2026-07-23 16:17:13 +00:00
Peter Steinberger
d893f79ccc fix(matrix): preserve encryption keys across snapshot upgrades (#112919)
* fix(matrix): migrate legacy crypto snapshots via doctor

* fix(matrix): harden snapshot migration failures

* fix(matrix): preserve unreadable crypto snapshots

* test(matrix): consolidate crypto snapshot coverage
2026-07-23 02:25:52 -04:00
Peter Steinberger
7497147519 refactor: hoist channel doctor migration helpers (#112782) 2026-07-22 22:53:39 -04:00