Commit Graph

44255 Commits

Author SHA1 Message Date
Peter Steinberger 57e862980b feat(gateway): carry machine class through session moves (#125292)
* feat(gateway): carry machine class through session moves

Profile move targets accept an optional machineClass with new-session
parity: validated in the protocol, persisted on the durable move intent
(bare nullable column, lazy same-version ALTER), replayed exactly by
restart recovery, and selectable from the Control UI move dialog.
Moving to the current profile with a different class resizes the
session's worker.

* fix(gateway): project placement facts on chat startup

chat.startup and chat.history built sessionInfo without the placement
projection sessions.list applies, so clients merging that row erased a
live worker placement and its move intent — the Runs on Cloud chip
disappeared after any turn until a full reload.

Reuse the canonical ensureColumn helper for the move table's additive
column instead of a hand-rolled PRAGMA read.
2026-08-17 14:25:13 -07:00
Josh Avant 8a7b6aa7da fix: keep session-memory slug generation tool-free (#125394) 2026-08-17 14:25:10 -07:00
Josh Avant 2f653a73c2 fix(skills): reject incomplete tar archive listings (#125406) 2026-08-17 14:15:43 -07:00
Peter Steinberger 6938026f20 fix(agents): honor system owner for unscoped reads (#125318)
* fix(agents): honor system owner for unscoped reads

* fix(gateway): resolve empty auth status owner
2026-08-17 14:07:56 -07:00
Shakker d802a8e8b4 fix: isolate preferred-provider metadata lookup (#125379)
Keep provider-scoped onboarding metadata resolution limited to the selected provider, preventing fallback OpenAI loading when Ollama is chosen without a configured model.

Refs #125373 and #125363.
2026-08-17 20:53:44 +01:00
Shakker d402e5d3f6 fix: scope onboarding model browsing (#125373)
Scope onboarding model discovery to the selected provider so browsing no longer loads unrelated provider setup surfaces while preserving route variants and global browsing behavior.

Fixes #125363.
2026-08-17 20:32:03 +01:00
Peter Steinberger 7f3b65e783 fix(plugins): expose background service failures in health (#125366)
* fix(plugins): surface service runtime failures

* chore: leave changelog to release tooling
2026-08-17 12:18:50 -07:00
Peter Steinberger 087d0ecca3 fix: surface skill and bootstrap load failures (#125348)
* fix: surface skill and bootstrap load failures

* fix: preserve oversized bootstrap diagnostics
2026-08-17 12:12:36 -07:00
Peter Steinberger 3a7df7a788 fix(hooks): honor explicit ingress targets and reject conflicts (#125351)
* fix(hooks): honor explicit ingress targets

* fix(hooks): reject blank direct agent ids
2026-08-17 11:52:45 -07:00
Peter Steinberger 45e6784338 feat(gateway): run disposable cloud workers through node transport (#125288)
* feat(gateway): converge cloud workers onto nodes

* fix(gateway): honor public URL for cloud enrollment

* fix(crabbox): execute cloud bootstrap package binary

* fix(gateway): bind cloud nodes in pairing transaction

* fix(crabbox): prefer exact installed cloud bootstrap

* fix(gateway): complete cloud node bootstrap

* fix(gateway): enforce cloud worker capability boundaries

* fix(gateway): complete cloud node migration

* fix(gateway): preserve paired node roles on teardown
2026-08-17 11:49:06 -07:00
Peter Steinberger 00b9626d13 fix: bound model-visible skills catalogs (#125346) 2026-08-17 09:54:52 -07:00
Peter Steinberger 8dfbaa6087 fix(cli): report plugin policy refusals as expected conditions (#125304) 2026-08-17 09:49:19 -07:00
Peter Steinberger b834477565 fix(cli): refuse live state reset and uninstall (#125253)
* fix(cli): guard live state cleanup

* fix(cli): preserve linked paths on cleanup failure

* fix(cli): retain gateway ownership through cleanup

* fix(cli): keep cleanup planning read-only

* fix(cli): skip mutating bootstrap for cleanup

* fix(apple): keep identity locks sandbox-writable

* docs(apple): clarify identity lock domains
2026-08-17 09:44:31 -07:00
Peter Steinberger 7170a6231a feat(agents): unify agent status into a durable progress_card (#125125)
* feat(agents): unify agent status into a durable progress_card

Replace the write-only update_plan to-do tool and the fragmented plan
rendering with one durable status artifact per session: progress_card
({plan?, markdown?}, replace-on-write, 8 KiB markdown / 50-step caps).
Cards persist in a lazy-additive session_progress_cards table in the
per-agent DB (no schema-version bump), broadcast progressCard.changed,
and render from the store with exactly one live placement per view
(session rail when visible, else the composer-adjacent bar); transcripts
collapse to one-line receipts, and the sidebar hovercard shows other
sessions' cards inline (markdown + <progress>, DOMPurify allowlist, no
iframes). The three stream-derived plan renderers and their dedup
heuristics are deleted.

Codex runs disable the native plan tool per thread
(tools.update_plan.enabled=false) and receive progress_card via the
dynamic-tool bridge; compaction restore now reinjects the card (steps +
bounded markdown). Card writes still emit the legacy plan stream event so
native apps and channels keep working until their per-platform
migrations. Policy names map update_plan -> progress_card; the shipped
tools.updatePlan=false kill switch is honored.

Net -277 production LOC; -480 test LOC.

* test(agents): regenerate Codex prompt snapshots for update_plan thread-config disable

* chore(protocol): allowlist progressCard.changed for native apps pending card migration

* fix(ci): repair progress card integration checks

* fix(codex): canonicalize native progress cards

* test(gateway): reconcile progress card method order

* test(codex): stabilize native approval fixture
2026-08-17 09:44:04 -07:00
Ayaan Zaidi 863f19b722 fix(ai): derive Responses compact threshold from active context budget (#125342)
The default OpenAI Responses compact_threshold was 70% of contextWindow alone; for gpt-5.6-sol (1.05M window, 272k active budget) that resolved to 735,000, above the ~252k prompt budget the runtime admits, so provider compaction never fired before local overflow handling. Threshold now uses 0.7 x min(contextTokens, contextWindow) (190,400 for Sol) on both the payload-policy and host-preflight paths; explicit responsesCompactThreshold still wins.
2026-08-17 22:09:50 +05:30
Peter Steinberger d742482f7b fix(agents): reject unusable worktree run admission (#125341) 2026-08-17 09:38:04 -07:00
Peter Steinberger 821f41e1cd fix(workers): propagate session permission context to worker placements (#125326)
* fix(workers): propagate session permission context

* test(workers): expect launch descriptor v4
2026-08-17 09:34:56 -07:00
Peter Steinberger 1298adfca7 fix(cron): distinguish missing automations from empty run history (#125343) 2026-08-17 09:34:38 -07:00
Peter Steinberger 1a821db049 fix(sessions): batch doctor SQLite imports (#125300)
Amp-Thread-ID: https://ampcode.com/threads/T-01a00a6a-b64e-74a5-8b15-2d3b966a468d

Co-authored-by: Amp <amp@ampcode.com>
2026-08-17 09:33:30 -07:00
Peter Steinberger efde610a9f fix(auto-reply): report failed queued replies after status delivery (#125325)
* fix(auto-reply): report partial followup delivery failure

* fix(auto-reply): classify followup batch failures

* fix(auto-reply): preserve followup delivery ownership

* test(auto-reply): consolidate followup delivery coverage
2026-08-17 09:23:24 -07:00
Peter Steinberger 793669c8f6 fix: targetless replies retain conversation correlation (#125283)
* fix(agents): preserve contextual reply correlation

Carry prepared reply policy into embedded and CLI message tools so targetless direct replies retain transport correlation and Reef thread identity.\n\nCloses #125279

* fix(reef): preserve unthreaded reply correlation

Keep reply-only inbound messages unthreaded unless the transport supplies a thread, while still anchoring new exchanges to their initiating envelope.\n\nRefs #125279
2026-08-17 06:40:28 -07:00
Peter Steinberger eb38d5e486 fix(reply): report settled delivery outcomes once (#124773)
* refactor(reply): publish settled dispatch receipts

* refactor(reply): isolate dispatch outcome accounting

* refactor(discord): infer settled dispatch result

* test(reply): model settled dispatch receipts

* test(reply): type settled receipt fixtures

* test(telegram): declare settled final receipt

* test(telegram): adapt legacy dispatch fixtures

* fix(reply): complete settled receipt compatibility

* test(channels): keep delivery suite within lint budget

* test(channels): reuse settled count fixture

* test(channels): consolidate receipt assertions

* test(channels): extract delivery receipt fixtures

* fix(qa): recover stopped clients after config restart

* fix(reply): settle deferred delivery receipts

* test(channels): share delivery turn fixtures

* fix(channels): preserve non-visible reconciliation

* fix(reply): preserve settled receipt compatibility

* refactor(reply): make settled receipts canonical

* refactor(reply): absorb settlement at dispatcher boundary

* test(matrix): prove settled receipt precedence

* refactor(sessions): extract prompt snapshot types

* fix(reply): restore queued admission counts
2026-08-17 06:38:16 -07:00
Peter Steinberger 7068006c78 fix(doctor): report cron config refusal as incomplete (#125282)
Amp-Thread-ID: https://ampcode.com/threads/T-01a00ae0-190d-718b-8a76-b75f3e8d1fae

Co-authored-by: Amp <amp@ampcode.com>
2026-08-17 06:13:09 -07:00
Peter Steinberger 11ebdfc9c3 fix(gateway): normalize TLS certificate pins (#125276)
* fix(gateway): normalize TLS certificate pins

* test(gateway): use valid TLS pin fixtures
2026-08-17 06:02:56 -07:00
Peter Steinberger 08622cd766 fix(ui): keep streamed replies ordered across steering (#125197)
* fix(ui): preserve steering stream order

Record exact steering provenance and keep cumulative assistant output on its causal side of persisted user turns across live streaming, terminal events, tool boundaries, and history reloads.

* chore(ci): refresh post-rebase gates

Tighten the inherited environment-variable budget and remove a stale test import exposed by the rebased lint gate.

* fix(ui): preserve terminal steer stream segment

Assert the causal stream rollover when a steer lands and move persisted split-layout normalization off the startup path to keep the Control UI bundle within budget.

* refactor(ui): extract split layout types

Keep the persisted split-layout normalizer off the interactive module cycle while preserving the Control UI startup bundle reduction.

* fix(gateway): resolve steering provenance at injection

* fix(gateway): confirm steering provenance after persistence

* refactor(ui): move live tool filtering to identity owner

* fix(ui): preserve queued user stream ceiling
2026-08-17 06:00:40 -07:00
Ayaan Zaidi d90dcc2111 feat(plugin-sdk): export saveMediaSource from media-store (#125278)
Plugins holding a remote URL had no non-deprecated Plugin SDK path to turn it into managed media; saveMediaSource was only reachable through the deprecated media-runtime barrel while docs pointed at media-store. Re-export it from the focused subpath and move the bundled qa-channel plugin off the deprecated barrel. Maintainer decision: full saveMediaSource (local path + HTTP(S)) is the supported media-store contract.

Fixes #125259
2026-08-17 12:54:52 +00:00
Peter Steinberger 914d8f6932 fix(onboard): keep completion permission errors nonfatal (#125263)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-17 05:48:02 -07:00
Peter Steinberger 429042b9e3 fix(ci): restore session type lint budget (#125272) 2026-08-17 05:46:45 -07:00
Peter Steinberger 4f898a4081 fix(state): migrate legacy state to system agent (#125266) 2026-08-17 05:32:40 -07:00
Peter Steinberger 66b8be04d9 fix(configure): report failed remote health checks (#125203)
Amp-Thread-ID: https://ampcode.com/threads/T-01a00b7c-b9f0-73d5-8fb7-e619e8e458e1

Co-authored-by: Amp <amp@ampcode.com>
2026-08-17 05:21:43 -07:00
Peter Steinberger 4eb6aa375f refactor(gateway): carry authoritative read facts (#125145)
* refactor(gateway): carry authoritative read facts

* fix(gateway): fence prepared device auth rotations

* fix(ci): split oversized session types
2026-08-17 05:13:35 -07:00
Peter Steinberger e6616fdc4c fix(sessions): surface cleanup failures and purge owned artifacts (#125217) 2026-08-17 04:43:33 -07:00
Peter Steinberger 4b0d573437 feat: session permission modes with worktree-scoped defaults (#124909)
* feat(gateway): add session permission modes

* feat(agents): enforce session permission policies

* test: cover session permission modes

* docs: explain session permission modes

* fix(agents): preserve apply patch default root

* feat(codex): map session permission modes

* feat(ui): add session permission controls

* test: cover session permission surfaces

* fix(agents): enforce session permissions from entry

* fix(codex): pass params object to requirements reader

* fix(codex): honor session permission modes

* fix(codex): preserve exec approval floors

* chore: revert changelog edit (release-owned)

* test: align full-mode promotion with upstream semantics

* chore(protocol): regenerate session permission models

* docs: register session permission modes

* fix(ui): use shared permission dropdown

* fix(sessions): restore permission mode contracts

* fix(ci): record session permission startup JS growth in the budget baseline

* refactor(agents): prepare session exec mode at dispatch

Host dispatch owns permissionMode→exec override preparation; the codex
plugin consumes prepared facts and the SDK barrel export is removed,
keeping the plugin-sdk surface at its recorded budget.

* test: type exec mode fixtures as ExecMode

* fix(codex): require admin scope for yolo permissions

* test: isolate codex permission command state

* ci: refresh PR checks against current main

* ci: refresh checks after gateway test repair

* test: fix main-fallout CI suites

* chore: refresh CI merge ref

* fix(worker): fence permission-mode cloud placements

* fix(sessions): clear worktree policy on detach

* chore(protocol): generate session permission mode enum

* test(gateway): type dispatch fixtures from session entries

* fix(ui): allow clearing session permission mode

* chore: refresh CI merge ref

* fix(ci): record permission picker startup growth in the budget baseline

* fix(gateway): gate session root projections
2026-08-17 04:37:35 -07:00
Ayaan Zaidi 75c5d9e208 fix(agents): show waiting reply when sessions_yield pauses a turn (#125106)
Show an explicit waiting acknowledgment when sessions_yield ends an otherwise-silent interactive turn, while keeping private resume context out of channel delivery and preserving existing visible replies.

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-17 17:01:48 +05:30
Peter Steinberger 91d3f533f1 fix: new sessions open promptly in Git workspaces (#124796)
* fix(gateway): unblock new session creation

* fix(gateway): fence session baseline capture

* chore(types): keep baseline claim private

* fix(sessions): settle reset diff baselines

* fix(sessions): preserve baseline invalidation

* test(agents): consolidate compaction ownership cases

* fix(sessions): fail closed on baseline persistence

* fix(sessions): fence baseline generations

* test(sessions): align authoritative baseline fixtures
2026-08-17 04:16:02 -07:00
Ayaan Zaidi e298277af9 fix: tool-heavy sessions survive runtime cutover (#125181)
Use canonical provider-visible projection for preflight context estimates, preserving older usage anchors without counting mirrored storage bytes.

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-08-17 16:45:54 +05:30
Peter Steinberger 2d3aaaa0d5 feat(node-host): support Cloudflare Access service tokens (#125193)
* feat(node-host): support Cloudflare Access service tokens

Carry SecretRef-backed, origin-bound Cloudflare Access credentials across node onboarding, gateway and worker connections, and node-owned worker transfers. Refs #125112.

* chore: align changed gate after rebase

* test(node-host): keep access proof within lint budgets

* style(node-host): keep supervisor within line budget

* fix(node-host): omit absent access config

* fix(node-host): reject Access credentials on plaintext routes

* fix(node-host): reject plaintext before ref resolution

* test: cover Access log redaction over TLS
2026-08-17 04:12:27 -07:00
Peter Steinberger e30b425e18 fix: recovery no longer claims interrupted commands succeeded (#125209)
* fix(agents): report interrupted tool outcomes honestly

Prevent restart recovery from claiming that an interrupted tool call completed when no successful matching result was recorded.

* fix(agents): keep ambiguous recovery restart-safe

Classify failed replay-unsafe tool results at the shared restart-recovery owner so interrupted side effects remain unavailable until their external state is verified.

* fix(agents): distinguish missing tool outcomes

Carry the existing missing_tool_result fact into projected Codex transcripts so restart recovery restricts only genuinely unknown outcomes, while confirmed failures remain retryable.
2026-08-17 04:11:57 -07:00
Peter Steinberger 9329e4d76a refactor(approvals): consolidate channel approval kind (#125215) 2026-08-17 04:08:10 -07:00
Peter Steinberger 27b77a901e feat(ui): make session references first-class links with titled chips and hovercards (#125014)
* feat(sessions): teach session tools the Control UI link rule

Gate guidance on publicOrigin plus enabled Control UI, with exact literal-URL fallback after short-link misses.

* feat(ui): linkify session keys in chat markdown

Match agent session keys structurally in plain text and inline code, then delegate canonical chat navigation.

Allowlist data-session-key through markdown sanitization.

Pathfinder: keep internal Control UI route anchors in-app by removing target="_blank" and external-link rel attributes while preserving external link behavior.

* feat(ui): session hovercard + titled session chips backed by controlUi.sessionPreview

* fix(gateway): scope controlUi.sessionPreview to caller-visible sessions

Hover previews now apply the same createSessionListEntryFilter predicate as
sessions.list, so identity-bearing non-admin callers cannot preview-by-key
incognito rows or non-owner drafts the sidebar hides. Regression test proves
the viewer/admin split; pre-fix run leaked ok-status metadata.

* feat(sessions): carry the session-link rule in tool result envelopes

Deferred-description mode hides prose tool descriptions at decision time. Carry the shared Control UI session-link sentence in successful session lookup result envelopes so every tool mode sees the rule.

* fix(ui): upgrade session chips on appearance, not first pointer event

* fix(android): regenerate gateway protocol methods

* test(gateway): track session preview release train

* perf(ui): lazy-load session hovercard registration

* fix(ui): keep session hovercards off sidebar navigation

* fix(ui): cancel routed session-link navigation

* fix(sessions): advertise forced-literal ~key URLs so short-ID collisions cannot misroute

* test(sessions): update forced-literal guidance expectation

* fix(ui): collision-proof raw-key navigation and SPA-route internal session URLs

* perf(ui): preserve session route lazy boundary

* fix(ui): defer unseeded session-preview fetches to hover intent

* fix(sessions): hard-cap the model-visible session-link base
2026-08-17 04:05:02 -07:00
Peter Steinberger bbe22082b0 fix(cli): keep gateway calls and diagnostics read-only (#125178)
* fix(cli): keep gateway diagnostics read-only

Direct gateway calls and diagnostic probes now preserve shared SQLite ownership instead of creating or mutating state during read-only operations.

Related: #101290
Follow-up to #125102

* fix(cli): keep required status probes read-only
2026-08-17 03:58:57 -07:00
Peter Steinberger 6d04fe5305 fix(heartbeat): avoid claiming excluded outcomes were recorded (#125207)
* fix(heartbeat): report accepted outcomes honestly

* test(heartbeat): refresh response tool snapshots

* fix(heartbeat): align tool catalog wording
2026-08-17 03:58:23 -07:00
Peter Steinberger 785c5bdb32 fix(state): keep unresolved legacy agent state advisory (#125172)
* fix(state): keep ownerless legacy agent state advisory

* refactor(state): validate legacy database inspection rows

* fix(state): reject invalid legacy agent owners
2026-08-17 03:57:29 -07:00
Peter Steinberger 8cae198210 fix(cli): default Windows completion to PowerShell (#125211)
Co-authored-by: Amp <amp@ampcode.com>
2026-08-17 03:50:52 -07:00
Peter Steinberger bb95d106d8 fix: keep image compression policy consistent during plugin reloads (#125182)
* fix: keep image compression policy consistent during plugin reloads

* fix: pin model static fallbacks to prepared metadata
2026-08-17 03:49:24 -07:00
Peter Steinberger 0bc877e889 fix(cron): deliver main reminders in the main session (#125198)
* fix(cron): route main reminders through main session

* refactor(cron): finish main reminder cleanup

* test(cron): align main reminder expectations
2026-08-17 03:35:55 -07:00
Peter Steinberger 353b497007 fix: report session changes during deletion (#125188)
* fix(sessions): report deletion lifecycle mismatches

* fix(sessions): translate late deletion conflicts

* refactor(sessions): move lifecycle snapshot equality
2026-08-17 03:26:57 -07:00
Peter Steinberger 916932b007 fix(agents): standardize image inspection as view_image (#125024)
* chore: refresh CI after main fix

* fix(agents): standardize image inspection as view_image

* fix(agents): preserve view_image activity display

* fix(agents): satisfy view_image display gates

* fix(ui): snapshot cloud worker draft before save

* perf(ui): compact fallback tool catalog

* fix(agents): preserve view_image upgrade boundaries

* chore(ui): refresh historical image display snapshot
2026-08-17 03:01:12 -07:00
Peter Steinberger 4ffcd972d3 fix(sessions): stop max-lines compaction backup leaks (#125183)
* fix(sessions): stop max-lines compaction backup leaks

* fix(sessions): reclaim legacy compact backups
2026-08-17 02:45:20 -07:00
Peter Steinberger 076a8cc616 fix(install): avoid unusable checkout directories after failed clones (#124872)
* fix(install): publish fresh git clones transactionally

Amp-Thread-ID: https://ampcode.com/threads/T-01a00ae0-190d-718b-8a76-b75f3e8d1fae

* fix(installer): preserve empty clone destinations transactionally

Amp-Thread-ID: https://ampcode.com/threads/T-01a00ae0-190d-718b-8a76-b75f3e8d1fae

* fix(update): satisfy transactional clone lint

Amp-Thread-ID: https://ampcode.com/threads/T-01a00ae0-190d-718b-8a76-b75f3e8d1fae

* test(update): type recovery directory assertion

* fix(installer): retain canonical clone checkout

Amp-Thread-ID: https://ampcode.com/threads/T-01a00ae0-190d-718b-8a76-b75f3e8d1fae

* fix(update): retain published checkout root

Amp-Thread-ID: https://ampcode.com/threads/T-01a00ae0-190d-718b-8a76-b75f3e8d1fae

* test(update): cover package preflight before clone

Amp-Thread-ID: https://ampcode.com/threads/T-01a00ae0-190d-718b-8a76-b75f3e8d1fae

---------

Co-authored-by: Amp <amp@ampcode.com>
2026-08-17 02:40:07 -07:00