Commit Graph

6812 Commits

Author SHA1 Message Date
Peter Steinberger f6fff4f7fd refactor: canonicalize aliases and classify test suites (#122407)
* refactor: use canonical re-export names

* fix(test): classify suite support as test source

* fix(agents): retarget gateway stub session-entry import

* test(gateway): retarget session-utils mock keys after alias removal
2026-08-11 21:18:34 -07:00
Peter Steinberger ae2158c0da fix(cloud-workers): start source bundles with vendored packages (#122400)
* test(qa): prove cloud worker mid-turn loss

* fix(cloud-workers): prune vendored workspace dependencies

* test(qa): keep SSH fixture type private
2026-08-11 20:32:54 -07:00
Peter Steinberger a5420dfd91 fix(windows): launch npm-installed native session CLIs (#122334)
* fix(windows): resolve runnable npm launchers

* fix(windows): preserve npm shim argv in terminal sessions
2026-08-11 18:41:35 -07:00
joshavant 2317ad082f test(ci): align release-gate manifest expectations 2026-08-11 20:35:35 -05:00
joshavant 49dabadf86 fix(ci): avoid unrelated iOS release-gate runs 2026-08-11 20:35:35 -05:00
Peter Steinberger 964c8c84c1 refactor: consolidate coercion ownership (#122299)
* refactor: consolidate coercion ownership

Centralize four canonical coercion helpers, migrate exact core and plugin duplicates through narrow Plugin SDK facades, and enforce declaration and plugin-normalization ownership boundaries.

The sweep adds eight focused SDK exports while deleting more production and tooling code than it adds. User-visible behavior is unchanged except for safer equivalent object and UI parsing at existing boundaries.

* fix: guard integer option ownership

Register resolveIntegerOption with the canonical function owner and extend the declaration-guard fixture so future local duplicates fail validation.

* fix: keep integer helpers on numeric facade

Remove the unshipped duplicate string-coerce exports and route every affected plugin consumer through the existing number-runtime contract.

* fix: point numeric coercion to number runtime

Make boundary and declaration diagnostics recommend the canonical numeric facade, with failing-before coverage for both guidance paths.
2026-08-11 17:14:53 -07:00
Jason (Json) 72d55fc12a fix(scripts): rewrite transitive OCM workspace packs (#122214) 2026-08-11 17:01:06 -07:00
Peter Steinberger 76c7cd7308 test(ci): trim duplicate SQLite lifecycle tours (#122308)
* test(ci): accelerate SQLite flip proof

* test(sessions): replace duplicate archive stress tour

* test(sessions): preserve SQLite lifecycle contracts

* test(sessions): drop duplicate archive assertions

---------

Co-authored-by: Amp <amp@ampcode.com>
2026-08-11 16:51:28 -07:00
joshavant 5f7ea6b548 fix(ui): lazy-load run inspector copy 2026-08-11 18:44:38 -05:00
Peter Steinberger 25f7fc0ec5 test(ci): skip unrelated Bun launcher builds (#122333)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-11 16:21:44 -07:00
Vincent Koc 1982aaa351 fix(test): isolate gateway helper env stubs (#122319) 2026-08-12 06:57:44 +08:00
Peter Steinberger c525f1a549 fix(windows): preserve Unicode LAN route aliases (#122263) 2026-08-11 15:21:37 -07:00
Sliverp 84c7d45f15 refactor(qqbot): install plugin from Tencent package (#107295)
* refactor(qqbot): remove bundled extension source

Mechanical deletion half of the #107295 squashed rebase; the catalog
repoint and host integration land in the follow-up commit.

Co-authored-by: sliverp <870080352@qq.com>

* refactor(qqbot): install plugin from Tencent package

Squashed rebase of #107295 onto current main. Repoints the official
external channel catalog at @tencent-connect/openclaw-qqbot@2.0.1 and
adapts onboarding, doctor migrations, secrets, build guards, and tests.

Documents the known limitation that the external package does not
support structured SecretRef clientSecret values; operators move those
to QQBOT_CLIENT_SECRET or clientSecretFile before upgrading.

Co-authored-by: sliverp <870080352@qq.com>

* fix(doctor): reuse shared hasOwnKey record helper

The rebased QQBot migration carried its own hasOwnKey export, colliding
with the one main now ships in legacy-config-record-shared.ts.

Co-authored-by: sliverp <870080352@qq.com>

* fix(plugins): carry catalog integrity through the update bridge

The externalized-bundled-plugin bridge dropped the official catalog's
expectedIntegrity pin, so bundled-user updates installed the external
npm package without integrity verification. The bridge now carries the
pin for the catalog's exact npm spec and both bridge install calls pass
it through; update-channel spec overrides intentionally skip the pin
since it only covers the pinned version.

Co-authored-by: sliverp <870080352@qq.com>

* chore(plugin-sdk): refresh per-entrypoint API baselines

The QQBot compat export and bundled-type removal shift 26 entrypoint
closure hashes in the new split baseline layout.

Co-authored-by: sliverp <870080352@qq.com>

* refactor(qqbot): drop helper reintroduced during rebase

Main's coercion consolidation added this file after the deletion
commit's base; its only consumers were the removed qqbot sources.

Co-authored-by: sliverp <870080352@qq.com>

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-08-11 15:10:27 -07:00
Josh Lehman d035dba6c7 chore: scope SQLite session lifecycle CI (#121917)
* oc-358: scope SQLite lifecycle CI

* chore(ci): cover shared session lifecycle owner
2026-08-11 15:06:46 -07:00
bᵣᵢₐₙ 8d034a7b61 fix(cron): stop advertising trigger-gated fields when cron triggers are disabled (#122052)
* fix(cron): stop advertising trigger-gated fields when cron triggers are disabled

When cron.triggers.enabled is off (the documented default posture), the
cron tool still advertised job.trigger/patch.trigger, schedule.kind
"stream" with its stream-only fields, and payload.kind "script" — all of
which the scheduler unconditionally rejects. Schema-eager models attach
junk triggers to plain reminder requests, get rejected, and retry-loop
without ever creating the job.

Gate those surfaces on the resolved config so they are only advertised
when the runtime can actually accept them, and swap the trigger guidance
for a short unavailable notice so the model tells the user instead of
polling or silently degrading the request. Config-less construction
paths keep the full surface.

Related: #119455

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(cron): restore config type import and regenerate schema contracts

Repairs rebase fallout and CI-contract consequences of the trigger gating:

- Re-import OpenClawConfig from config/types.openclaw.js; the rebase crossed
  #121768 which removed the re-export from config/config.js, stranding
  resolveCronTriggersEnabled's signature.
- Guard the destructured tool in the MCP gating test for
  noUncheckedIndexedAccess.
- Collapse the hookContext merge object to one line: the added config
  pass-through tipped openclaw-tools.ts over the max-lines ratchet (701/700).
- Regenerate prompt snapshots (cron description narrowed under
  triggers-disabled harness config; ~3k chars per prompt) and the plugin-sdk
  API baseline (CronToolOptions gained the optional config member, visible
  via codex-mcp-projection).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* chore(cron): align schema contracts with current main

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Co-authored-by: Josh Lehman <550978+jalehman@users.noreply.github.com>
2026-08-11 21:48:14 +00:00
wangmiao0668000666 9dc5a9a152 fix(logging): publish diagnostics ZIP through staged atomic overwrite (#122130)
* fix(logging): publish diagnostics ZIP through staged atomic overwrite

A named support export wrote the in-memory ZIP buffer straight to the
final path, so a failed or interrupted overwrite truncated the previous
archive, and an existing file kept its pre-existing (potentially
permissive) mode since writeFile only applies mode on creation.

Route publication through writeExternalFileWithinRoot's sibling staging:
the new archive is written to a private sibling, fsynced, and atomically
renamed over the final path. A failed publication leaves the previous
ZIP untouched with no staging residue, and the rename always installs
the staged file's 0o600 mode. The command now returns the actual
published path.

Fixes #122064

* test(logging): prove failed zip replacement stays atomic

* test(sqlite): create private reliability fixture

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-08-11 14:12:39 -07:00
Vincent Koc aa52ebaef3 fix(test): serialize default e2e runner (#122203)
* fix(test): serialize default e2e runner

* docs(test): document serial e2e default
2026-08-12 05:01:04 +08:00
Peter Steinberger e74be5d41d refactor: eliminate final wrapper-shadowing hazards (#122157)
* refactor: disambiguate wrapper-shadowed exports

* test: align renamed session and facade boundaries

* test: cover renamed runtime mock exports

* refactor: align remaining wrapper owner call sites

* test: align overlap-rebased runtime mocks

* refactor: preserve public SDK names after overlap rebase

* chore: regenerate wrapper shadowing baselines

* test: align cron model selection mocks
2026-08-11 13:34:24 -07:00
Peter Steinberger 8f4a90a518 fix(media): decode local file URLs safely (#122192)
* fix(media): decode local file URLs safely

* refactor(media): remove obsolete helper exports
2026-08-11 13:19:09 -07:00
Peter Steinberger a40df57bae refactor(agent-runner): split run policy ownership (#122209)
* refactor(agent-runner): split tool-call normalization ownership

* refactor(agent-runner): split incomplete-turn ownership

* test(agent-runner): hide incomplete-turn test helper

* test(ci): route split incomplete-turn tests

* test(ci): enumerate split incomplete-turn tests

* test(vitest): route split incomplete-turn tests to their serial shard
2026-08-11 13:06:29 -07:00
Jason (Json) 09c39e0ec5 fix(scripts): keep bundled channel smoke standalone (#122212) 2026-08-11 13:05:46 -07:00
Peter Steinberger 8c567306ba fix(openai): remove duplicate GPT-5.6 picker entry (#122178)
* fix(openai): remove duplicate GPT-5.6 picker entry

* test(gateway): split OpenAI model picker coverage

* test(openai): align canonical model fixtures

* chore(plugin-sdk): refresh agent harness API baseline
2026-08-11 12:29:36 -07:00
Ayaan Zaidi 746a188c90 refactor(media): collapse attachment byte classification into media-core (#122168)
Attachment MIME gating and extraction dispatch used nine separate byte policies across five files; the allowlist could approve one MIME while dispatch observed another after a second sniff. @openclaw/media-core/attachment-classify now owns byte sniffing, text heuristics, extension mapping, and the seven attachment classes; the cache stores one classification that gates and dispatch share. Channel-declared MIME leads with the transport Content-Type as a byte-arbitrated hint, normalizeMimeType folds YAML/XML synonyms so existing configured allowlists keep matching, and input_file API callers keep declared-MIME precedence over cosmetic filenames. Net -135 production LOC.

Proof: 2,153 focused tests across media-core/media-understanding/media plus boundary-contract and deadcode-mirror suites; ClawSweeper local review clean (round 5, zero findings); live Telegram default-turn probe green.

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-11 19:10:49 +00:00
Peter Steinberger 3d76246792 refactor: eliminate final export name collisions (#122083)
* refactor: resolve final export name collisions

* refactor: update remaining collision rename consumers

* style: format rebased auth helpers

* test: update remaining session entry mocks

* test: update remaining runtime mock exports

* test: update delivery info path mock

* refactor: reconcile combined collision sweeps

* chore: regenerate collision and sdk baselines
2026-08-11 11:18:24 -07:00
Vincent Koc 5bc7efe746 fix(test): keep CLI process suites in owner lane (#122160) 2026-08-12 02:07:51 +08:00
Peter Steinberger ebb2770000 refactor: eliminate export name collisions (#122084)
* refactor: eliminate export name collisions

* chore(scripts): burn resolved collision baselines

* refactor: narrow legacy session load options

* chore: refresh SDK and session debt baselines

* refactor: adopt upstream secrets collision fix

* test(plugin-sdk): mock renamed session store core

* fix(scripts): track renamed session accessor core
2026-08-11 10:41:50 -07:00
Vincent Koc 1fb715853c fix(qa): resolve Docker harness script entrypoints (#121548)
Punchcard-Session: amber-workshop-workshop-36
2026-08-12 01:23:20 +08:00
Peter Steinberger cad77fb39c refactor: consolidate remaining coercion helpers (#122020) 2026-08-11 10:22:01 -07:00
Peter Steinberger a580c2afa1 fix(windows): parse tasklist CSV for port hints (#122126) 2026-08-11 10:08:08 -07:00
Peter Steinberger 1dcac5b15f fix: open terminals no longer delay gateway updates (#121601)
* fix(gateway): allow updates with open terminals

* fix(updater): support terminal policy upgrades

* chore(plugin-sdk): refresh API baseline
2026-08-11 09:37:58 -07:00
Vincent Koc 8d3f3377da fix(ci): make Control UI artifact validation consistent (#122086) 2026-08-12 00:11:22 +08:00
Jason (Json) 94ae370bcc fix(updater): verify launchd bootstrap postcondition (#121747)
* fix(updater): verify launchd bootstrap postcondition

* test(commands): align learn prompt invariants

* test(approvals): align plugin runtime event kinds

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-08-11 09:02:15 -07:00
Vincent Koc afc644464d fix(ci): bound hosted Android build memory (#122088) 2026-08-11 23:57:22 +08:00
Peter Steinberger d1452fb5d1 refactor(plugin-sdk): split API baseline by entrypoint (#122082) 2026-08-11 08:54:42 -07:00
Peter Steinberger f798f9999b fix(agent-tools): expand Windows home paths (#122071) 2026-08-11 08:28:35 -07:00
Peter Steinberger db73b59c04 refactor: burn wrapper shadowing baseline entries (#122040)
* refactor: burn wrapper shadowing entries

* chore: refresh wrapper shadowing baselines

* test: update secrets runtime state mocks

* fix(ci): absorb Control UI build identity variance
2026-08-11 08:24:03 -07:00
Vincent Koc 6472d22a77 fix(ci): budget expanded survivor groups (#122058) 2026-08-11 22:44:21 +08:00
Peter Steinberger e390781534 refactor: burn cross-directory export name collisions (#121893)
* refactor: name subsystem logger exports

* refactor(test): distinguish exported test doubles

* refactor: consolidate canonical owner helpers

* refactor: give cross-domain helpers distinct names

* chore(lint): ratchet collision debt baselines

* fix(test): complete collision rename consumers

* fix(test): update remaining collision mock consumers

* fix(test): update transcript reader mock export

* refactor: keep embedded logger name at its owner

* fix(test): align embedded logger mock with owner

* refactor: name shared assistant phase extraction

* fix(ui): update assistant phase extractor import

* chore(generated): refresh collision and SDK baselines

* style(test): format merged plugin mocks

* chore(sdk): refresh API content hashes
2026-08-11 06:50:22 -07:00
Peter Steinberger 8dace97c2e perf(test): cut workflow guard overhead (#122038)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-11 06:29:08 -07:00
Peter Steinberger fd8b1fb1b9 fix(windows): preserve provider local service env overrides (#122027) 2026-08-11 06:28:24 -07:00
Peter Steinberger 686294f9f8 test(sqlite): right-size reliability crash payloads (#122016)
* test(sqlite): right-size reliability crash payloads

* test(agents): replace hanging provider error integration

---------

Co-authored-by: Amp <amp@ampcode.com>
2026-08-11 05:26:07 -07:00
Peter Steinberger 2cc11aff38 test(scripts): streamline Crabbox wrapper fakes (#122007)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-11 04:33:11 -07:00
Peter Steinberger 03f56cfbc3 fix(memory): accept Windows extra-file Markdown casing (#121976)
* fix(memory): accept Windows extra-file Markdown casing

* fix(memory): keep extra-file casing policy private
2026-08-11 04:21:15 -07:00
Peter Steinberger 992126e382 refactor(sessions): drop the Sqlite infix from session-accessor exports (#121536)
* refactor(sessions): drop the Sqlite infix from session-accessor exports

The storage-neutral seam completed its file->SQLite swap on 2026-07-27;
the Sqlite-infixed export names and their X-as-Y rename blocks were the
fossil of that migration, giving every accessor operation two greppable
names. Rename ~148 exports to their canonical names at the definition
sites, delete the message-cut facade (its conflict->failed mask had one
consumer, which already handles conflict), collapse the remaining pure
delegates, and keep honest SQLite-mechanics names (scope resolution,
canonical repair, in-transaction primitives, storage-row types). The main
barrel's exported surface is byte-identical. Net -203 production LOC.
Part 2 of the session-accessor dual-layer collapse (part 1: #121316).

* fix: repair main-breaking lint/type/test failures blocking PR CI

Three breakages landed on main that push CI's changed-scope never runs:
a caught-error cause missing in the release-validation script and two
type errors in the package-acceptance test (direct commit 1f591bba56),
and a memory-host regression where fs-safe 0.5.4 (#121508) started
throwing FsSafeError("not-file") for extra-path reads whose parent chain
hits a regular file, breaking the missing-file empty-text contract that
rejection unchanged.

Item 4 repairs managed-image action E2E narrowing from bad30d5a74 (#77017).
Item 5's chat-message mock repair was superseded upstream by 750d0dcd9e, whose broader fetch typing and explicit download capture preserve the same contract.
Item 6 restores #121258's cursor token contract after #77017 hard-coded pointer.
Item 7's managed-image thumbnail-path repair was superseded upstream by 750d0dcd9e, which preserves the same contract in main's reorganized URL structure.
Item 8 records #121600's explicit command-bearing lifecycle classification.
Item 9's cron assertion repair was superseded upstream by 3cd034f7a8, whose exact diagnostic rewrite includes the same redacted alert contract.
Item 10 forwards fs-safe 0.5.4 bigint lstat options through the snapshot mock.
Item 11 refreshes release-matrix test ownership after 1f591bba56.
Item 12 awaits f3e1efead48's setup-admission settlement in direct session tests.
Item 13's media FileStore-key repair was superseded upstream by cf432ec871, which fixes the same Windows root cause at the owner boundary.
Item 14 regenerates Swift approval reviewer fields added by 9935ca3b30.
2026-08-11 11:13:29 +00:00
Peter Steinberger 26d0158e50 test(packaging): speed tarball integrity checks (#121999)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-11 03:56:38 -07:00
Peter Steinberger 33ce7313d7 improve: speed up plugin npm package tests (#121989)
* test(packaging): collapse duplicate plugin installs

* test(packaging): combine bundled dependency proof

* test(packaging): name packed artifact proof

---------

Co-authored-by: Amp <amp@ampcode.com>
2026-08-11 03:35:33 -07:00
Peter Steinberger 2731dc24e5 fix(plugin-sdk): keep inbound reply shim through next SDK major (#121922)
* fix(plugin-sdk): honor major-gated reply shim retirement

* fix(plugin-sdk): preserve compat code literals

* chore(plugin-sdk): refresh compatibility API baseline
2026-08-11 03:18:07 -07:00
thomas.szbay ecc6d5a9fe fix(e2e): download non-root installer before execution
Download the non-root Docker smoke installer before executing it.

- preserve the existing 30-second connection and 300-second transfer limits
- clean up the temporary installer on success or failure
- prove failed downloads cannot execute partial installer content

Co-authored-by: thomas.szbay <xydigit-zt@users.noreply.github.com>
Punchcard-Session: golden-lantern-meadow-0x
2026-08-11 18:12:52 +08:00
wangmiao0668000666 c719cbbfe9 fix(e2e): preserve Unicode in Telegram proof tails (#109940)
Punchcard-Session: ember-brook-workshop-qc

Co-authored-by: wangmiao0668000666 <290215524+wangmiao0668000666@users.noreply.github.com>
2026-08-11 18:09:29 +08:00
Peter Steinberger db33736137 test(tooling): decouple MinGit curl assertion (#121977) 2026-08-11 03:07:13 -07:00