Commit Graph

78532 Commits

Author SHA1 Message Date
Peter Steinberger cb6204c570 test(sqlite): stabilize VACUUM interruption proof 2026-08-12 05:00:37 -07:00
Peter Steinberger 79ac476b0f fix(test): type CDP DNS lookup mocks (#122607)
Amp-Thread-ID: https://ampcode.com/threads/T-019ff3db-c467-70ad-8ed3-81f2ba94b0c0

Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 04:45:15 -07:00
Vincent Koc 3e6aec1d55 fix(state): avoid startup ownership snapshots (#122518) 2026-08-12 19:07:15 +08:00
Vincent Koc ce56c40dab fix(test): wait for gateway hook model activity (#122584) 2026-08-12 19:02:21 +08:00
James Tatum 5235269b3c fix(agents): heartbeats lose all conversation context on claude-cli chat↔heartbeat transitions (#121509)
* fix(agents): resolve session-stable reply mode for direct resolver turns

Heartbeat wakes and other direct getReplyFromConfig callers bypass
dispatch, so no session-stable delivery mode reached their CLI binding
facts and prepare computed no messageToolPolicyHash, while dispatched
chat turns hashed the stable mode. resolveCliSessionReuse treats that
one-sided hash as a policy change, hard-invalidating the binding on
every chat<->heartbeat transition and leaving heartbeats to run in
fresh CLI sessions with no conversation history (historyPrompt=none).

Extract the synthetic-turn stable-mode resolution that
prepareAgentCommandExecution already used into
resolveSessionStableReplyMode, and apply it in prepareReplyRunContext
whenever a synthetic turn arrives without dispatch's injected mode, so
every turn kind on a session derives the same binding facts and hash.

Fixes #121485

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

* fix(agents): derive synthetic binding facts from the dispatch policy owner

Consolidate the synthetic-turn stable-mode resolution onto dispatch's own
policy pieces instead of a simplified parallel resolver:

- resolveVisibleRepliesPolicy is extracted from dispatch prepare-context
  (configured visible-replies guard + harness default chain) and shared, so
  the fallback and dispatch cannot drift on harness defaults, live-vs-entry
  chat facts, or ExplicitDeliverRoute.
- The stable fact now applies dispatch's messageToolAvailable downgrade via
  the canonical tool-policy resolvers: tool-only delivery with a policy-denied
  message tool records automatic, matching dispatch.
- Synthetic turns no longer fall back to their effective turn mode: a
  response-tool heartbeat's message_tool_only is per-turn enforcement, not
  session policy, and previously bypassed the stable fallback entirely.

Regression coverage: response-tool heartbeat facts match dispatched turns,
and a message-tool-denied config downgrades the synthetic stable fact.

Refs #121485

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

* fix(agents): keep the session-stable reply mode sender-independent

Dispatch's stable-mode downgrade used the turn's sender-aware message-tool
availability, so a sender-scoped message denial hashed the stable policy as
automatic on chat turns while sender-less synthetic turns hashed tool-only —
the same binding reset loop on another axis.

resolveStableMessageToolAvailability becomes the one sender-independent
owner: dispatch passes it as sessionStableMessageToolAvailable for the
stable-mode resolution only (effective per-turn enforcement keeps the
sender-aware verdict), and synthetic binding facts already consume it.
Computed only when the visible-replies candidate is message_tool.

Refs #121485

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

* fix(agents): derive stable reply facts from session surfaces, not wake plumbing

Third-pass review fixes on the #121485 consolidation:

- Strip system-event wake providers ("heartbeat", "cron-event") from the
  stable context and resolve origin-less entries as internal, so synthetic
  facts take the same internal-channel branch dispatch's live webchat turns
  do instead of falling through to harness defaults.
- Fall back to persisted session facts (delivery channel/origin, groupId,
  groupChannel/subject, accountId) for the sender-independent availability
  stack, so bare-ctx callers like command prepare resolve the same
  group/account-scoped policies as dispatched turns; dispatch now passes its
  session entry too.
- Collapse the redundant second mode resolution into the availability
  downgrade, surface dispatch's injected stable mode separately from
  resolvePromptSourceReplyMode so the synthetic slot has one owner, and
  reuse resolveTurnModelOverride instead of an inline copy.
- Refresh docs/.generated/plugin-sdk-api-baseline.jsonl: closure hashes only
  (17 exports, zero declaration changes, verified) — plugin-sdk reply/meeting
  entrypoints transitively bundle the reply pipeline this branch refactors.

Regression: origin-less entry heartbeat resolves internal-automatic facts.

Refs #121485

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

* chore: adapt to main module moves and split API baseline

Mechanical rebase refresh onto d3696f8d76: subagent-capabilities moved to
src/agents/subagents/spawn/, and the plugin-sdk API baseline is now
per-entrypoint content hashes (#122082) — regenerated for the reply-pipeline
closure this branch touches.

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

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-12 16:25:38 +05:30
Peter Steinberger 6780d87e4f test(gateway): skip reconnect wall-clock waits (#122588)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 03:49:04 -07:00
Peter Steinberger ee535c5e1d fix(doctor): report legacy cache scan failures (#122585)
* fix(doctor): report usage cache scan failures

Treat only missing legacy cache paths as absent and surface permission or I/O failures without partial cleanup.

* fix(doctor): preserve cache scan error causes
2026-08-12 03:48:17 -07:00
Pavan Kumar Gondhi 92f5f07da1 fix(browser): keep guarded CDP sockets on validated endpoints [AI] (#114506)
* fix(browser): keep guarded CDP sockets on validated endpoints

* fix(browser): avoid retrying rate-limited CDP discovery

* fix(browser): close Chrome MCP CDP policy gaps

* test(browser): match Chrome MCP policy error

* test(browser): satisfy transport type and lint checks

* fix(browser): narrow guarded CDP transport changes

* fix(browser): separate upload filesystem locality

* fix(browser): keep strict remote CDP hosts untrusted
2026-08-12 16:16:12 +05:30
Peter Steinberger 786c646d88 improve(ci): rebalance compact Node shards from hosted medians (#122547)
* ci: refresh compact Node shard timings

Amp-Thread-ID: https://ampcode.com/threads/T-019ff3db-c467-70ad-8ed3-81f2ba94b0c0

* docs(ci): clarify compact planner counts

Amp-Thread-ID: https://ampcode.com/threads/T-019ff3db-c467-70ad-8ed3-81f2ba94b0c0

---------

Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 03:41:34 -07:00
Peter Steinberger fea6d96378 fix(qa): artifact write failure preserves previous files (#122580)
* fix(qa): publish suite artifacts atomically

* test(qa): consolidate artifact durability coverage
2026-08-12 03:29:34 -07:00
Josh Avant 562391b9af feat(audit): explain denied operator approvals (#119815)
* Audit: add durable decision receipts

* Audit: route generic decision facts through writer

* Audit: satisfy strict decision count typing

* Test: align decision writer type coverage

* Refactor: isolate decision receipt projection

* Fix: preserve ambiguous approval correlation

* Fix decision coverage across pages

* Fix approval coverage across corrupt pages

* Fix decision summaries across retention and paging

* Remove superseded decision fact count path

* Keep session-derived approval links conservative

* Test decision paging at owner boundary

* Audit: bind approval receipts to exact execution

* Test: keep decision receipt coverage focused

* docs(agents): preserve decision receipt ownership

* Docs: refresh Plugin SDK split baselines

* Docs: require opt-in for future decision facts

* Fix: bound decision receipt inspection
2026-08-12 05:23:29 -05:00
clawSean 654fc632cd docs(backup): describe manual restore flow (#86971)
* docs(backup): describe manual restore flow

* docs(backup): make restore copy-back fail closed

* docs(backup): make inspect-and-stage block fail closed

Add set -euo pipefail to the first restore staging snippet so a failed
openclaw backup verify stops before mktemp/tar extraction, matching the
fail-closed copy-back block. Addresses ClawSweeper P1 on docs/cli/backup.md.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* docs(backup): reconcile restore guidance with exclusions

Punchcard-Session: brisk-harbor-harbor-6w

* docs(backup): centralize archive restore guidance

Punchcard-Session: calm-cedar-workshop-by

---------

Co-authored-by: clawSean <260045960+clawSean@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: Vincent Koc <vincentkoc@ieee.org>
2026-08-12 18:09:26 +08:00
Peter Steinberger fa4a197177 perf: accelerate sqlite reliability proof (#122576)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 03:07:19 -07:00
Vincent Koc fb788e7a3e refactor(diagnostics-otel): unify event attribute projection (#122559) 2026-08-12 18:06:08 +08:00
Vincent Koc 9324843d42 fix(release): trust frozen beta Telegram candidates (#122575) 2026-08-12 18:03:15 +08:00
SunnyShu 6fa383695f fix(gateway): preserve inbound media references in chat history (#122031)
* fix(gateway): retain managed inbound media reference in chat history
* fix(gateway): simplify inbound media projection (#122031) (thanks @SunnyShu0925)

---------

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
Co-authored-by: SunnyShu0925 <shu.zongyu@xydigit.com>
2026-08-12 15:31:39 +05:30
Vincent Koc 2c26f13606 fix(qa): accept staged compaction summaries (#122528) 2026-08-12 17:52:14 +08:00
Pavan Kumar Gondhi 5eb18c1387 fix(ios): keep authenticated Control UI pages bound to the trusted Gateway [AI] (#119906)
* fix(ios): enforce gateway TLS pins in control pages

* test(ios): run control UI trust regressions in CI

* test(ios): avoid nested Testing macros

* fix(ios): preserve control page navigation

* fix(ios): keep authenticated control pages on origin

* fix(ios): canonicalize control page IPv6 hosts

* chore(ios): refresh native i18n inventory

* fix(ios): normalize default TLS challenge ports

* fix(apps): share gateway TLS authority matching

* test(apps): fix authority CI validation

* chore(ci): drop control UI test routing
2026-08-12 15:18:19 +05:30
Peter Steinberger cb58073a90 fix(ui): paginate all active tasks (#122565)
Preserve task-list cursors and drain every active page so supported running work remains visible and cancellable.
2026-08-12 02:46:55 -07:00
Peter Steinberger 30131a572b perf: speed changed-test import scans (#122572)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 02:30:32 -07:00
Peter Steinberger 7e42dae611 refactor(memory-core): split index manager along the inheritance chain (#122540)
* refactor(memory-core): split index manager along the inheritance chain

* fix(memory): restore the manager lazy boundary

* refactor(memory-core): delete dead manager plumbing

* chore(lint): ratchet max-lines baseline after memory manager split

* fix(memory): keep the manager out of the runtime facade

* test(memory): cover transitive manager facade imports
2026-08-12 02:28:20 -07:00
Peter Steinberger e5dd254561 fix(memory-wiki): publish lint report atomically (#122568) 2026-08-12 02:23:48 -07:00
zhifu gao 42ad83142e fix(whatsapp): label voice transcripts as untrusted (#113111)
* fix(whatsapp): label voice transcripts as untrusted

* fix(whatsapp): preserve audio provenance in group history

Frame deferred voice transcripts while retaining their structured audio facts for later model-visible replay.

Refs #87269

---------

Signed-off-by: zhifu gao <lauragpt@users.noreply.github.com>
Co-authored-by: Vincent Koc <vincentkoc@ieee.org>
Co-authored-by: zhifu gao <lauragpt@users.noreply.github.com>
2026-08-12 17:14:55 +08:00
Peter Steinberger 5350b92dc8 fix(browser): wake extension relay through gateway (#122537)
* fix(browser): wake extension relay through gateway

* fix(browser): preserve manual extension relay pairing
2026-08-12 02:13:03 -07:00
Vincent Koc 08b7fcc05e test(cli): cover node daemon adapters (#122562)
Punchcard-Session: golden-valley-cedar-5x

Co-authored-by: xin zhuang <65798732+1052326311@users.noreply.github.com>
2026-08-12 17:09:07 +08:00
Peter Steinberger 66009308bb test: parallelize doctor process coverage (#122563)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 02:08:55 -07:00
Vincent Koc 7e2ec43e54 fix(ci): keep hosted gate verifier standalone (#122561)
Punchcard-Session: silver-valley-orchard-nq
2026-08-12 17:08:09 +08:00
Peter Steinberger d44f70eb4b feat(pairing): one-paste device pairing via oc-pair setup links (#120768)
* feat(pairing): one-paste device pairing via oc-pair setup links

Implements milestone 3 from docs/plan/runners.md.

* fix(pairing): sign bootstrap handshake, keep URL candidates, wire pairing countdown

* test(gateway): update client callsite guard

* fix(pairing): preserve setup URL context paths

* fix(ui): keep pairing help aligned with setup mode

* fix(pairing): isolate bootstrap credentials

* perf(ui): keep one-paste pairing within bundle budget

* refactor(pairing): isolate native pair URL prefix parsing

* fix(pairing): preserve candidate lifecycle state

* fix(pairing): retire shared credentials after bootstrap

* fix(pairing): apply rotated manifest through client owner

* test(pairing): prove bootstrap retirement across reconnect

* fix(pairing): preserve native gateway context paths

* fix(pairing): carry native context paths through reconnect

* fix(ios): preserve encoded gateway context path

* chore(plugin-sdk): refresh pairing API baselines
2026-08-12 02:01:33 -07:00
Josh Avant 3b01ea7905 fix(audit): show authenticated users for Gateway runs (#122484)
* fix(audit): show authenticated users for Gateway runs

* fix(audit): keep profile labels out of sessions

* test(qa): verify session label retention at storage

* fix(sessions): preserve canonical profile ownership

* test(qa): require full identity inspection proof

* docs(agents): preserve execution identity ownership boundary
2026-08-12 08:50:37 +00:00
Peter Steinberger 6d973d114f test: trim duplicate target registry coverage (#122555)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 01:46:38 -07:00
Peter Steinberger 92ed766673 fix(camera): publish URL downloads atomically (#122550) 2026-08-12 01:38:18 -07:00
Peter Steinberger 432ccac74b fix(channels): honor terminal reaction holds (#122544)
Serialize done and error holds before restoring initial reactions, and restore Slack error reactions through the shared lifecycle.
2026-08-12 01:36:54 -07:00
Vincent Koc 1672d78d17 refactor(plugins): share bounded run id tracking (#122362) 2026-08-12 16:23:33 +08:00
Peter Steinberger e4da1c8d8b improve: speed up secrets runtime coverage tests (#122538)
* test: speed up secrets runtime coverage

* test: respect extension contract boundary

---------

Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 01:22:36 -07:00
Peter Steinberger 31aa7c7c75 refactor(agents): split cli-runner into concept modules (#122442)
* refactor(agents): split CLI runner concepts

* chore(lint): ratchet cli-runner max-lines baseline

* refactor(agents): remove stale runner import

* refactor(agents): preserve cleanup error typing

* refactor(agents): disambiguate CLI backend predicate

* test(agents): align code-mode pending boundary

Fixes red main: both host calls are unsettled when the guest snapshot is first parked; later waits still prove that settled calls are filtered.

* test(agents): tolerate code-mode settlement race

Fixes red main: the fast host call may settle as the guest snapshot is parked, while the deliberately slow call must remain pending.
2026-08-12 01:20:27 -07:00
Peter Steinberger 08142099da refactor(plugins): remove test-only facades and adapter (#122532)
* refactor(plugins): trim test-only facades

* refactor(whatsapp): remove legacy outbound adapter
2026-08-12 01:20:09 -07:00
Vincent Koc dfbdbf2a67 fix(provider-runtime): retry transient socket failures (#122535)
* test: cover UND_ERR_SOCKET retry recovery

Punchcard-Session: golden-cedar-brook-4q

* fix(provider-runtime): retry UND_ERR_SOCKET failures

Punchcard-Session: golden-cedar-brook-4q
2026-08-12 16:16:22 +08:00
Vincent Koc 83649466fa fix(qa): isolate gateway child skip controls (#122534) 2026-08-12 16:08:43 +08:00
Peter Steinberger 85a176b98a feat(ui): commit-scoped session diff viewer with file, sync, and view menus (#122470)
* feat(ui): commit-scoped session diff viewer with file, sync, and view menus

The Control UI session diff panel becomes a dense Amp-style viewer: per-file
menus (copy path, open file, reveal in file tree, open in editor), a Sync
Locally popover with a copyable git fetch command, view options (collapse all,
wrapping, split/unified layout), and a sticky footer that reports how far the
branch is ahead of its merge base and switches between all changes,
uncommitted work, and individual commits.

sessions.diff gains an additive scope param (all | uncommitted | commit) plus
commits, aheadCount, and mergeBase metadata. Commit-scope diffs read only the
object database, skip untracked collection, and bypass session-start baseline
filtering; unknown commits surface a typed unavailableReason. Offscreen file
bodies use content-visibility so large diffs stay responsive.

* fix(ui): satisfy session diff CI gates

* fix(gateway): fence commit-scoped session diffs to the advertised branch history

ClawSweeper found that commit-scoped sessions.diff accepted any commit resolvable in the checkout. Fence operator.read commit reads to the advertised merge-base..HEAD history and cover sibling-branch and base-history commits.
2026-08-12 01:08:33 -07:00
Vincent Koc 716f996be8 fix(ci): prepare sandbox before repo E2E (#122525) release-publish/716f996be8db-1786550775 2026-08-12 16:08:19 +08:00
Vincent Koc b8a0fa2e7a fix(plugins): derive media aliases from exports (#122523) 2026-08-12 16:03:34 +08:00
Peter Steinberger 5a643e3543 fix(plugins): keep packed entries consistent through package lifecycle (#121174)
* fix(plugins): own packed entry lifecycles by package

Persist package ownership per runtime child, route lifecycle actions through one closed resolver, reconcile removed child policy during updates, and retain rollback generations until durable config/index commit.

* fix(plugins): break uninstall policy import cycle

* test(plugins): model package ownership in lifecycle fixtures
2026-08-12 00:49:29 -07:00
Peter Steinberger 016c5aa772 ci: balance Control UI E2E shards by source size (#122527)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 00:48:14 -07:00
Peter Steinberger bfe1f33ea0 improve(ui): make Control UI feel native on mobile (#122492)
* improve(ui): make Control UI feel native on mobile

* fix(ui): keep coarse-pointer input floor text-scale aware

* fix(ui): let self-sized controls opt out of the touch input floor

* fix(ui): fold per-control coarse-pointer font floors into the shared touch floor
2026-08-12 00:46:35 -07:00
Peter Steinberger 94c28e093d fix(test): route agent directory runs to owning shard (#122514)
* fix(test): route agent directories to owner projects

* fix(test): preserve invalid signal diagnostics
2026-08-12 00:44:49 -07:00
Peter Steinberger af3550df73 fix(ui): confirm automation removal (#122505)
Bind irreversible Cron removal to the current Gateway, admin scope, state object, and job revision across the confirmation modal.
2026-08-12 00:41:17 -07:00
Peter Steinberger b46181bfc0 fix(agent): post-tool timeout does not replay completed tools (#122516)
* fix(agent): prevent replay after post-tool timeout

* fix(agent): narrow settled tool assistant evidence
2026-08-12 00:31:55 -07:00
Peter Steinberger 1da8fffbcb improve: speed up secrets audit test shard (#122504)
* test: speed up secrets audit coverage

* test: complete daemon plugin fixtures

---------

Co-authored-by: Amp <amp@ampcode.com>
2026-08-12 00:23:34 -07:00
Peter Steinberger 0de17482ae feat(gateway,ui): quiet Where picker, placement chip, and projects read model (#120804)
* feat(gateway): projects.list groups known checkouts by repo identity

Implements docs/plan/runners.md milestone 4 derived projects read model.

* feat(ui): regroup the Where picker by gateway, devices, and cloud

* feat(ui): placement chip shows where a session runs with reclaim

Implements docs/plan/runners.md milestone 4 placement display and reclaim.
2026-08-12 00:21:23 -07:00
Peter Steinberger fc0147b529 test(plugins): remove duplicate setup cases (#122515) 2026-08-12 00:19:22 -07:00