Commit Graph

37549 Commits

Author SHA1 Message Date
Peter Lee
ef95c5d74e fix(discord): reset progress drafts across queued turns (#102341)
* fix(discord): guard progress draft collapse to prevent re-collapse on cleaned stream

Commit 86ea382 added a progressDraftStartedBeforeFinal latch that snapshots
hasStarted at markFinalReplyStarted time. This correctly preserves collapse
eligibility when an abort cancels the compositor gate before
shouldCollapseProgressDraft runs.

However the latch was never cleared. After markPreviewFinalized turned the
draft into a summary, hasProgressDraftStarted remained true permanently. In
multi-tool turns with multiple final-payload deliveries, this caused
shouldCollapseProgressDraft to re-trigger collapse on an already-cleaned or
sealed draft stream, corrupting downstream delivery state and causing tool
results to render as image content blocks instead of text.

Fix: add a progressDraftCollapsed guard set by markPreviewFinalized that
prevents hasProgressDraftStarted from returning true after the draft has been
collapsed into a summary. Reset the guard on handleAssistantMessageBoundary
so followup/queued turns start fresh.

Per Discord channel session, all tool results rendered as image content
blocks. Model received (see attached image) placeholders instead of text.

Fixes #100782

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* fix(discord): use valid table/chunk mode literals in collapse-guard tests

* test(discord): add abort-race gate-cancellation latch survival test

* fix(discord): consume progress draft collapse once

Co-authored-by: xialonglee <li.xialong@xydigit.com>

* fix(discord): retain progress receipt on retry

Co-authored-by: xialonglee <li.xialong@xydigit.com>

* fix(discord): rearm queued progress drafts

Co-authored-by: xialonglee <li.xialong@xydigit.com>

* test(discord): assert progress lifecycle outcomes

Co-authored-by: xialonglee <li.xialong@xydigit.com>

* fix(discord): reset queued progress turn state

Co-authored-by: xialonglee <li.xialong@xydigit.com>

* test(discord): model recreated progress drafts

Co-authored-by: xialonglee <li.xialong@xydigit.com>

* fix(discord): serialize progress draft rotation

Co-authored-by: xialonglee <li.xialong@xydigit.com>

* fix(discord): isolate queued draft generations

Co-authored-by: Peter Lee <xialonglee@users.noreply.github.com>

* test(discord): align synchronous draft rotation

Co-authored-by: Peter Lee <xialonglee@users.noreply.github.com>

* fix(discord): distinguish draft rotation ownership

Co-authored-by: Peter Lee <xialonglee@users.noreply.github.com>

* chore: keep release notes in pull request

---------

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-11 02:59:29 -07:00
NIO
98fb858769 docs(cli): clarify that exec-policy show and approvals get exclude per-session /exec overrides (#94999)
* docs(cli): clarify exec-policy show and approvals get exclude per-session /exec overrides

* refactor(cli): centralize session exec override note

* test(cli): cover node exec override note

* test(cli): use complete node policy fixture

---------

Co-authored-by: NIO <nocodet@mail.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-11 02:58:37 -07:00
Peter Steinberger
d8bf51b462 fix(discord): single-source thread-binding default placement and guard artifact parity (#104342)
* fix(discord): single-source thread-binding default placement and guard artifact parity

* fix(tests): load thread-binding parity artifacts via sanctioned contract test helpers
2026-07-11 02:50:53 -07:00
xydt-tanshanshan
eb2f763674 fix(agents): add tool-activity heartbeat to keep subagent alive during tool calls (#95536)
* [AI] fix(agents): add run-scoped tool-activity heartbeat to prevent premature subagent idle timeout

Subagent LLM idle watchdog tripped during long-running tool calls because
tool completions did not reset the idle timer.

Implement a per-run tool-activity heartbeat:
1. notifyToolActivity(runId) — published from embedded-runner tool
   execution wrappers (attempt.ts) whenever a tool completes
2. onToolActivity(runId, listener) — consumed by streamWithIdleTimeout
   to reset the idle watchdog on tool completion
3. getLastToolActivityMs(runId) — shared timestamp Map so pre-stream
   activity is visible to armTimer before the first stream iteration
4. clearToolActivityRun(runId) — wired into the run lifecycle finally
   block to clean up listener sets and timestamps when the run exits

Scoped per-run via runId-keyed Maps to prevent concurrent runs from
resetting each other's idle watchdogs.

Related to #94124

* [AI] fix(agents): copy plugin/channel/before-tool-call metadata onto heartbeat tool wrappers

* [AI] test(agents): add metadata preservation regression tests for heartbeat tool wrapper

* [AI] fix(agents): preserve terminal presentation metadata on heartbeat tool wrapper

* [AI] chore: update test comment for four metadata copy calls

* fix: add periodic heartbeat during tool execution

Fire notifyToolActivity at tool start and every 60s via setInterval
so long-running tools survive the 120s LLM idle watchdog.

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

* fix: remove useless catch clause (no-useless-catch)

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

* fix: preserve Code Mode control-tool identity through heartbeat wrapper

Adds copyCodeModeControlToolIdentity() to replicate the WeakSet
membership that markCodeModeControlTool() sets. Without this,
the heartbeat wrapper drops Code Mode identity for exec/wait
tools, weakening before_tool_call policy and approval handling.

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

* fix: wrap deferred directory tools with heartbeat

resolveDeferredTool hydrates hidden catalog tools outside the
effectiveTools.map() wrapper, so they bypassed the periodic
notifyToolActivity heartbeat. Wrap the hydrated execute function
with the same start/interval/complete notification pattern.

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

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Vincent Koc <vincentkoc@ieee.org>
2026-07-11 17:50:33 +08:00
Peter Steinberger
6e81c548fc fix: bind macOS node allowlist commands safely (#104337)
* fix: bind macOS node allowlist commands safely

* chore: leave node fix notes in PR
2026-07-11 02:27:59 -07:00
Peter Steinberger
0ef9a62eaf fix(codex): allow slower Mac session catalogs (#104332) 2026-07-11 02:05:55 -07:00
chenyangjun-xy
c557246437 fix(watch): defer restart when dist/entry.js is missing mid-rebuild (#99972)
* fix(watch): defer restart when dist/ is mid-rebuild (#99603)

Defer gateway:watch child restart when run-node's build/runtime-postbuild
readiness contract reports a hard dist/ failure. Only defers on conditions
where the child physically cannot start, preserving normal restart behavior
for soft staleness that run-node can rebuild on start.

Hard failures (defer restart):
  - missing_dist_entry (mid-rebuild)
  - missing_bundled_plugin_dist_entry
  - missing_private_qa_dist
  - missing_runtime_postbuild_output

Soft staleness (allow restart, run-node rebuilds):
  - missing_build_stamp (w/ direct entry.js check for masked case)
  - git_head_changed, dirty_watched_tree
  - config_newer, build_stamp_missing_head, source_mtime_newer

isBuildReadyForRestart delegates to resolveBuildRequirement and
resolveRuntimePostBuildRequirement from run-node.mjs, using the
watcher process environment for consistency with the child runner.
200ms polling with 5-min timeout. Child-exit bounded recovery.
Clears stale restartRequested on timeout/poll errors.

Ref: #99603
Co-Authored-By: Claude <noreply@anthropic.com>

* fix(watch): deduplicate deferral loops, add single-flight guard, remove lint suppression

- Extract deferUntilBuildReady(onReady, onTimeout) shared helper,
  replacing the near-identical pollBuildReady and pollAfterChildExit.
- Add single-flight guard (deferredRestartActive) so concurrent file
  change events during deferral coalesce into one poll loop instead of
  spawning a git-subprocess storm.
- Replace inline .catch arrow callback with method-style call, removing
  the oxlint-disable-next-line suppression and its allowlist entry.
- Add tests: coalescing multiple changes, requestRestart recovery.

Ref: #99603
Co-Authored-By: Claude <noreply@anthropic.com>

* fix: keep gateway watch alive during concurrent builds

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-11 01:58:16 -07:00
Peter Steinberger
7c9cb54f09 fix: Codex CLI login fails during fresh Mac setup (#104150)
* fix(onboarding): preload Codex runtime for setup probe

* fix(onboarding): refresh Codex runtime discovery

* fix(onboarding): use native Codex CLI auth

* fix(onboarding): probe bundled Codex login

* chore(macos): refresh onboarding i18n inventory

* fix(onboarding): live-test custom Codex providers
2026-07-11 01:53:49 -07:00
Vincent Koc
9e39e9a862 fix(memory): complete llama runtime diagnostics 2026-07-11 16:40:14 +08:00
Vincent Koc
85a96409f1 feat(memory): surface llama.cpp diagnostics 2026-07-11 16:40:14 +08:00
Peter Lee
585914fcd5 fix(channels): stop unavailable targets repeating plugin scans (#100377)
* fix(channels): suppress repeated failed bootstrap

Co-authored-by: Peter Lee <li.xialong@xydigit.com>

* docs(changelog): credit recent fixes

---------

Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-11 01:29:33 -07:00
Vincent Koc
f71255e475 fix(agents): redact service request diagnostics 2026-07-11 16:22:22 +08:00
Vincent Koc
50429157e3 fix(embeddings): preserve provider alias cache identity 2026-07-11 16:22:22 +08:00
Vincent Koc
bb65e79ae9 fix(agents): honor configured provider URL aliases 2026-07-11 16:22:22 +08:00
Vincent Koc
67106e94a3 fix(agents): redact inherited service diagnostics 2026-07-11 16:22:22 +08:00
Vincent Koc
ffc9585624 test(agents): model default local service overlays 2026-07-11 16:22:22 +08:00
Vincent Koc
1667654caa fix(agents): allow default loopback service endpoints 2026-07-11 16:22:22 +08:00
Vincent Koc
065873e5ec fix(lmstudio): preserve local service endpoint forms 2026-07-11 16:22:22 +08:00
Vincent Koc
d2ac533c6c fix(embeddings): skip local services for remote overrides 2026-07-11 16:22:22 +08:00
Vincent Koc
64c50da1b2 fix(agents): drain local service output on failed startup 2026-07-11 16:22:22 +08:00
Vincent Koc
6e3c3d5384 fix(plugin-runtime): bind service probes to configured endpoints 2026-07-11 16:22:22 +08:00
Vincent Koc
1b3438d7ec fix(plugin-runtime): keep local service config host-owned 2026-07-11 16:22:22 +08:00
Vincent Koc
fd62672ec8 fix(agents): drain local service output after readiness 2026-07-11 16:22:22 +08:00
Vincent Koc
ffe9e22b23 test(agents): bound startup-only service diagnostics 2026-07-11 16:22:22 +08:00
Vincent Koc
a46f780874 fix(agents): stop retaining local service runtime output 2026-07-11 16:22:22 +08:00
Vincent Koc
ee4e8038f9 test(gateway): cover embedding local service injection 2026-07-11 16:22:22 +08:00
Vincent Koc
b085184d08 fix(gateway): acquire embedding local services 2026-07-11 16:22:22 +08:00
Vincent Koc
839892e4c4 test(agents): track local service temp directories 2026-07-11 16:22:22 +08:00
Vincent Koc
e413d36054 fix(agents): satisfy diagnostics snapshot lint 2026-07-11 16:22:22 +08:00
Vincent Koc
a74c92f27c fix(agents): unref local service diagnostics after readiness 2026-07-11 16:22:22 +08:00
Vincent Koc
317d9d772f fix(plugin-runtime): preserve local service hook projections 2026-07-11 16:22:22 +08:00
Vincent Koc
ccab708c16 fix(plugin-sdk): align local service release contract 2026-07-11 16:22:22 +08:00
Vincent Koc
e62c216d75 refactor(embeddings): inject local service acquisition 2026-07-11 16:22:22 +08:00
Vincent Koc
84393bea7a fix(agents): avoid retaining local service env values 2026-07-11 16:22:22 +08:00
Vincent Koc
6adeae6cfd fix(embeddings): lease OpenAI-compatible local services 2026-07-11 16:22:22 +08:00
Vincent Koc
c58690804f feat(plugin-sdk): expose provider local service leases 2026-07-11 16:22:22 +08:00
Vincent Koc
4228ae93c8 refactor(agents): generalize provider local service leases 2026-07-11 16:22:22 +08:00
Peter Steinberger
7bf80dc2c6 chore(tooling): enforce formatting and refresh TypeScript checks (#104239)
* chore(tooling): enforce current formatter and refresh checks

* chore(tooling): keep release changelog formatter-owned

* chore(tooling): retain compatible Node type surface

* ci: enforce formatting for docs-only changes

* ci: isolate docs formatter check

* chore(tooling): apply updated lint and format rules

* chore(tooling): satisfy updated switch lint

* style(ui): apply Linux formatter layout

* test(doctor): match quiet local audio contribution

* test(doctor): assert quiet output only

* test(doctor): follow restored information contract
2026-07-11 01:09:51 -07:00
Alix-007
5219c9353d fix(tts): bound voice-list requests (#102865)
* fix(microsoft): add timeout to voices list request

* fix(tts): bound voice-list requests

Co-authored-by: llagy009 <0668001470@xydigit.com>

---------

Co-authored-by: llagy009 <0668001470@xydigit.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-11 00:55:06 -07:00
Peter Steinberger
8804a41269 fix(doctor): restore local audio information (#104281)
Co-authored-by: Peter Steinberger <peter@steipete.me>
2026-07-11 00:41:58 -07:00
Peter Steinberger
ebc848deec feat: sidebar update card (web + macOS) with app-first mac update flow and Sparkle beta track (#104171)
* feat: sidebar update card (web + macOS) with app-first mac update flow and Sparkle beta track

Squashed from claude/update-notification-display-c6cfb9 after semantic merge
with #104178 (channel-aware CLI installs). See PR #104171 body for details.

* chore(i18n): resync generated inventories after rebase

* chore(i18n): resync locale metadata after rebase
2026-07-11 00:34:10 -07:00
Peter Steinberger
675f3ed048 fix(channels): remove duplicate set-profile action (#104235) 2026-07-11 00:26:01 -07:00
Peter Steinberger
c16bd0df8d feat(control-ui): show non-main gateway checkout branch in sidebar footer (#104262)
Source-checkout (non-release) gateways now report their git branch in the
Control UI bootstrap config; the sidebar footer renders it in red next to
the connection dot. Package installs, main/master, and detached HEAD never
show it.
2026-07-11 00:25:43 -07:00
NIO
27b6b67af1 refactor(status): skip duplicate channel summary scans (#95263)
* fix(status): report skipped channel credential checks accurately

* refactor(status): skip duplicate channel summary scans

Co-authored-by: NIO <nocodet@mail.com>

* test(status): exercise configured channel summary

---------

Co-authored-by: NIO <nocodet@mail.com>
Co-authored-by: Peter Steinberger <steipete@gmail.com>
2026-07-11 00:25:31 -07:00
Peter Steinberger
624b2e355f fix(doctor): register local audio health check (#104237)
Co-authored-by: Peter Steinberger <peter@steipete.me>
2026-07-11 00:23:04 -07:00
Ayaan Zaidi
f2a0f00567 fix(agents): keep exact tool allowlists on owning factories (#104213)
* refactor(agents): centralize core tool factory descriptors

---------

Co-authored-by: Ayaan Zaidi <hi@obviy.us>
2026-07-11 12:44:37 +05:30
Peter Steinberger
394bd1b489 fix: make LaunchAgent plists launchd-readable (#104228) 2026-07-11 00:12:48 -07:00
Peter Steinberger
f94a7dc183 feat(codex): supervise native Codex sessions (#104045)
* feat(codex): add native session supervision

* fix(codex): harden supervision integration

* fix(codex): preserve locked harness ownership

* fix(codex): fence native session archive

* fix(codex): revalidate archive binding ownership

* feat(codex): integrate supervision runtime

* feat(sessions): preserve harness-owned execution

* feat(sessions): persist harness ownership invariants

* feat(gateway): enforce harness-owned sessions

* feat(setup): enable detected Codex supervision

* feat(mac): expose supervised Codex sessions

* feat(ui): make Codex sessions actionable

* docs(codex): document session supervision

* test(codex): cover integration ownership

* chore(i18n): refresh supervision inventories

* fix(setup): finalize Codex activation atomically

* test(codex): narrow binding store update

* fix(sessions): preserve legacy model locks

* test(macos): serialize Codex catalog fixtures

* fix(sessions): preserve legacy lock admission

* chore(i18n): reconcile supervision metadata

* test(sessions): mark legacy lock fixture

* fix(macos): drain final Codex catalog frame

* docs: leave supervision note to release

* style(macos): satisfy Codex catalog type length

* chore: record session accessor seam owners

* fix(macos): honor configured Codex supervision

* fix(codex): preserve harness-owned model locks

* fix(codex): satisfy supervision lint gates

* chore(i18n): refresh native supervision inventory

* fix(codex): align supervision validation contracts

* fix(codex): close supervision boundary gaps

* fix(codex): preserve supervision activation contracts

* fix(codex): dispose standalone supervision runtime

* fix(codex): pin supervised source connection

* fix(plugins): bind delegated runs to exact session target

* fix(codex): scope supervised sessions to configured agents

* fix(codex): fingerprint effective supervision home

* fix(codex): normalize supervision plugin policy

* fix(codex): keep supervised bindings stable across upgrades

* fix(codex): guard all supervised binding connections

* fix(codex): preserve catalog filters and pending CAS identity

* fix(codex): preserve supervision identity for diagnostics

* fix(codex): bind uncertain commits to supervision connection

* fix(codex): satisfy supervision type boundaries

* fix(macos): reconcile current main validation

* fix(codex): handle absent runtime config in supervision

* fix(doctor): own local audio acceleration check

* fix(codex): satisfy integration lint gates

* fix(codex): satisfy lifecycle safety guards
2026-07-11 00:12:08 -07:00
Peter Steinberger
ae2c6117d3 feat(ui): full-page New session screen with gateway folder browser (#104238)
* feat(gateway): add admin-only fs.listDir host directory listing

* feat(ui): replace new-session dialog with full-page /new screen and folder browser

* fix(ui): drop unnecessary template literal in new-session page

* refactor(ui): rename request token locals for review-bundle hygiene

* fix(ui): preserve typed draft on agent hydration and clear stale folder listings

* fix(ui): gate new-session submit on agent hydration and keep live folder edits

* test(ui): use exact textbox selector in new-session e2e

* test(ui): deep-link new-session e2e so agents.list override supplies workspace

* chore(i18n): translate new-session strings and refresh native inventory

* chore(i18n): reconcile locale metadata after rebase
2026-07-11 00:10:48 -07:00
Peter Steinberger
1e660ac7b2 fix: preserve runtime plugin assets after build (#104229) 2026-07-11 00:07:59 -07:00