Compare commits

...

13 Commits

Author SHA1 Message Date
acp-release-bot[bot]
505f9c13c0 chore(main): release 0.36.0 (#683)
🤖 I have created a release *beep* *boop*
---


##
[0.36.0](https://github.com/agentclientprotocol/claude-agent-acp/compare/v0.35.0...v0.36.0)
(2026-05-18)


### Features

* Add experimental session delete support
([#682](https://github.com/agentclientprotocol/claude-agent-acp/issues/682))
([2162d5a](2162d5af62))
* Support experimental additionalDirectories field
([#684](https://github.com/agentclientprotocol/claude-agent-acp/issues/684))
([f37e9a0](f37e9a0d47))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: acp-release-bot[bot] <246668977+acp-release-bot[bot]@users.noreply.github.com>
2026-05-18 13:02:28 +02:00
Ben Brandt
f37e9a0d47 feat: Support experimental additionalDirectories field (#684) 2026-05-18 10:51:45 +00:00
Ben Brandt
2162d5af62 feat: Add experimental session delete support (#682)
- **Update Agent Client Protocol SDK to 0.22.0**
- **feat: Add session delete support**
2026-05-18 10:43:07 +00:00
Ben Brandt
798844726f chore: tighten local-command-stdout handler comment and pass full options (#678)
## Summary

Follow-up cleanup to #649. Two small changes:

- **Tighten the comment block** above the marker-strip branch in
`acp-agent.ts:1119`. The original 15-line block restated history that
already lives in the PR description; replaced with a 5-line "what this
does, and why the no-op case is preserved" comment that points at the
replay path for parallel context.
- **Forward `clientCapabilities`, `parentToolUseId`, `cwd`, and
`taskState`** to `toAcpNotifications` so the new strip-and-render call
matches the sibling call below it at `acp-agent.ts:1192`. Without these
the rendered output loses threading under a wrapping tool use and skips
terminal-output detection.
- **Only log the raw payload when nothing renders** — previously every
marker-containing message was logged AND rendered. Now we render the
stripped prose if anything remains, and fall back to logging only the
pure-marker case (e.g. `/compact`).

## Test plan

- [x] `npm run check` (lint + format) — passes
- [x] `npm run build` (tsc) — passes
- [x] `stripLocalCommandMetadata` unit tests — 8 passed

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-18 00:45:33 +02:00
acp-release-bot[bot]
f6e12d425e chore(main): release 0.35.0 (#670)
🤖 I have created a release *beep* *boop*
---


##
[0.35.0](https://github.com/agentclientprotocol/claude-agent-acp/compare/v0.34.1...v0.35.0)
(2026-05-16)


### Features

* **deps:** bump actions/create-github-app-token from 3.1.1 to 3.2.0
([#669](https://github.com/agentclientprotocol/claude-agent-acp/issues/669))
([47df1f2](47df1f2a0b))
* **deps:** bump hono from 4.12.18 to 4.12.19 in the minor group
([#671](https://github.com/agentclientprotocol/claude-agent-acp/issues/671))
([5d7165d](5d7165d961))
* **deps:** update to claude-agent-sdk 0.3.143
([#664](https://github.com/agentclientprotocol/claude-agent-acp/issues/664))
([27ca2e5](27ca2e5d40))
* Use SDK settings resolution for defaults
([#677](https://github.com/agentclientprotocol/claude-agent-acp/issues/677))
([eb1259c](eb1259cf88))


### Bug Fixes

* Add task hooks for plan state updates
([#676](https://github.com/agentclientprotocol/claude-agent-acp/issues/676))
([5ff7d50](5ff7d50f0e))
* render local-command-stdout messages instead of dropping them
([#649](https://github.com/agentclientprotocol/claude-agent-acp/issues/649))
([3b9b7d5](3b9b7d5a56))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: acp-release-bot[bot] <246668977+acp-release-bot[bot]@users.noreply.github.com>
2026-05-16 23:41:18 +02:00
Wandering Consciousness
3b9b7d5a56 fix: render local-command-stdout messages instead of dropping them (#649)
AI disclaimer: I identified this bug after noticing that custom skills
produced no output within the Zed Thread/Claude Agent UI. I used Claude
to investigate the issue and develop the fix. I have manually verified
the equivalent fix against an installed
`@zed-industries/claude-code-acp@0.16.1` (the deprecated package Zed
currently ships): custom slash commands that previously produced empty
threads now render the model's response correctly after Zed restart.

## Summary

The live `case "user" / "assistant"` handler in `src/acp-agent.ts` drops
every SDK message whose string content contains
`<local-command-stdout>`. The branch was added to tolerate `/compact`'s
malformed output, but its side-effect is silencing every successful
slash command invocation — custom user-defined skills (whose expanded
bodies arrive wrapped in `<command-*>` + `<local-command-stdout>`
markers) and built-in commands that emit textual output through these
tags.

## Symptom in ACP clients

User types `/some-command` (custom skill, or one of the affected
built-ins). Thread renders the user's `/some-command` bubble at the top,
then nothing — no expanded skill body, no model response. Under the hood
the model has actually received the expansion and produced a turn, but
the user message carrying the expansion never reaches the UI, and the
cascade of subsequent assistant content gets visually decoupled.

In CLI Claude Code the same expansion is printed to the terminal, so the
asymmetry is purely client-side.

## Fix

This repo already ships `stripLocalCommandMetadata` (and its underlying
`stripMarkerTags` helper) — they return `null` for marker-only payloads
and the stripped prose otherwise. They are already wired into session
replay/load (`acp-agent.ts:1385`) but not into the live handler.

The change wires the same helper into the live handler: strip the
markers and route what remains through the existing `toAcpNotifications`
path, preserving the message's role. Pure-marker payloads (e.g.
`/compact`'s) still no-op via the `null` branch, so the existing
`/compact works` integration test in `src/tests/acp-agent.test.ts`
continues to pass.

## Why the previous behaviour was conservative-but-wrong

The inline comment notes the filter exists for `/compact`'s SDK-side
malformed output. That tradeoff swallows a much larger class of
legitimate output (anything that uses `<local-command-stdout>` to wrap
real prose) to avoid one specific command's noise. With
`stripLocalCommandMetadata` available, the conservative behaviour can
target exactly the empty-after-strip case (still `null` → no-op) without
affecting messages that have real prose alongside markers — which is
exactly the regression case the helper's tests were written to cover
(see `src/tests/acp-agent.test.ts:1145-1163`, *"in the original bug
report the entire /model preamble and the user's real 'hi' prompt were
concatenated into a single message. We want to strip the marker tags and
preserve the real prose, not drop the whole message."*).

The fix applies that same principle to the live handler, where the
helper is most needed.

## Refs

- `zed-industries/claude-code-acp#624` — "'Skill' Session Updates
missing when invoked via slash command". The reporter correctly
diagnoses the mechanism: *"Claude just attaches the skill directly to
context when the /command is used, which means the skill loader isn't
used."* The skill body arrives wrapped in markers and gets dropped by
this filter.
- `zed-industries/claude-code-acp#642` — built-in slash commands
(`/usage`, `/status`, `/model`, `/memory`, `/permissions`, `/agents`,
`/mcp`) emit no output when invoked. Same root cause: their output
arrives in messages tagged with `<local-command-stdout>` and is filtered
out.

Both upstream issues remain open against the old repo
`zed-industries/claude-code-acp` and have no comments / linked PRs yet.
Cross-linking here so this PR can be the closing reference for both.

## Test plan

- [x] `npm run check` (lint + format) — passes
- [x] `npm run build` (tsc) — passes
- [x] `npx vitest run src/tests/acp-agent.test.ts -t
"stripLocalCommandMetadata"` — 8 passed
- [ ] Existing `/compact works` integration test — needs a CLI
environment to run; relies on the `null` branch preserving the no-op
behaviour for marker-only payloads, which the helper tests already cover

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-05-16 21:31:05 +00:00
Ben Brandt
eb1259cf88 feat: Use SDK settings resolution for defaults (#677) 2026-05-16 23:08:50 +02:00
Ben Brandt
5ff7d50f0e fix: Add task hooks for plan state updates (#676) 2026-05-16 21:05:27 +00:00
dependabot[bot]
47df1f2a0b feat(deps): bump actions/create-github-app-token from 3.1.1 to 3.2.0 (#669)
Bumps
[actions/create-github-app-token](https://github.com/actions/create-github-app-token)
from 3.1.1 to 3.2.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/actions/create-github-app-token/releases">actions/create-github-app-token's
releases</a>.</em></p>
<blockquote>
<h2>v3.2.0</h2>
<h2><a
href="https://github.com/actions/create-github-app-token/compare/v3.1.1...v3.2.0">3.2.0</a>
(2026-05-12)</h2>
<h3>Features</h3>
<ul>
<li>add support for enterprise-level GitHub Apps (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/263">#263</a>)
(<a
href="952a2a7073">952a2a7</a>)</li>
<li>support full repository names in <code>repositories</code> input (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/372">#372</a>)
(<a
href="85eb8dd414">85eb8dd</a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><strong>deps:</strong> bump <code>@​actions/core</code> from 3.0.0
to 3.0.1 in the production-dependencies group (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/364">#364</a>)
(<a
href="43e5c345bf">43e5c34</a>)</li>
<li>validate private-key input (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/376">#376</a>)
(<a
href="f24bbd8964">f24bbd8</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/actions/create-github-app-token/blob/main/CHANGELOG.md">actions/create-github-app-token's
changelog</a>.</em></p>
<blockquote>
<h1>Changelog</h1>
<h2><a
href="https://github.com/actions/create-github-app-token/compare/v3.1.1...v3.2.0">3.2.0</a>
(2026-05-12)</h2>
<h3>Features</h3>
<ul>
<li>add support for enterprise-level GitHub Apps (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/263">#263</a>)
(<a
href="952a2a7073">952a2a7</a>)</li>
<li>support full repository names in <code>repositories</code> input (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/372">#372</a>)
(<a
href="85eb8dd414">85eb8dd</a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li><strong>deps:</strong> bump <code>@​actions/core</code> from 3.0.0
to 3.0.1 in the production-dependencies group (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/364">#364</a>)
(<a
href="43e5c345bf">43e5c34</a>)</li>
<li>validate private-key input (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/376">#376</a>)
(<a
href="f24bbd8964">f24bbd8</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="bcd2ba4921"><code>bcd2ba4</code></a>
chore(main): release 3.2.0 (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/370">#370</a>)</li>
<li><a
href="f24bbd8964"><code>f24bbd8</code></a>
fix: validate private-key input (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/376">#376</a>)</li>
<li><a
href="363531b6d9"><code>363531b</code></a>
docs: capitalize Git as a proper noun in README (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/374">#374</a>)</li>
<li><a
href="fd2801133e"><code>fd28011</code></a>
docs: update procedure to configure Git (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/287">#287</a>)</li>
<li><a
href="85eb8dd414"><code>85eb8dd</code></a>
feat: support full repository names in <code>repositories</code> input
(<a
href="https://redirect.github.com/actions/create-github-app-token/issues/372">#372</a>)</li>
<li><a
href="c9aabb8372"><code>c9aabb8</code></a>
build(deps-dev): bump yaml from 2.8.3 to 2.8.4 in the
development-dependencie...</li>
<li><a
href="e02e816e55"><code>e02e816</code></a>
build(deps-dev): bump undici from 7.24.6 to 8.2.0 (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/366">#366</a>)</li>
<li><a
href="8d835bfd37"><code>8d835bf</code></a>
build(deps-dev): bump esbuild from 0.27.4 to 0.28.0 in the
development-depend...</li>
<li><a
href="952a2a7073"><code>952a2a7</code></a>
feat: add support for enterprise-level GitHub Apps (<a
href="https://redirect.github.com/actions/create-github-app-token/issues/263">#263</a>)</li>
<li><a
href="43e5c345bf"><code>43e5c34</code></a>
fix(deps): bump <code>@​actions/core</code> from 3.0.0 to 3.0.1 in the
production-dependenc...</li>
<li>Additional commits viewable in <a
href="1b10c78c78...bcd2ba4921">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/create-github-app-token&package-manager=github_actions&previous-version=3.1.1&new-version=3.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-05-16 22:26:39 +02:00
dependabot[bot]
5d7165d961 feat(deps): bump hono from 4.12.18 to 4.12.19 in the minor group (#671)
Bumps the minor group with 1 update:
[hono](https://github.com/honojs/hono).

Updates `hono` from 4.12.18 to 4.12.19
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/honojs/hono/releases">hono's
releases</a>.</em></p>
<blockquote>
<h2>v4.12.19</h2>
<h2>What's Changed</h2>
<ul>
<li>ci: pin GitHub Actions to SHAs by <a
href="https://github.com/yusukebe"><code>@​yusukebe</code></a> in <a
href="https://redirect.github.com/honojs/hono/pull/4932">honojs/hono#4932</a></li>
<li>fix(serveStatic): make options parameter optional in all adapters by
<a href="https://github.com/mixelburg"><code>@​mixelburg</code></a> in
<a
href="https://redirect.github.com/honojs/hono/pull/4934">honojs/hono#4934</a></li>
<li>fix(cookie): return the first cookie when there are multiple cookies
with the same name by <a
href="https://github.com/usualoma"><code>@​usualoma</code></a> in <a
href="https://redirect.github.com/honojs/hono/pull/4922">honojs/hono#4922</a></li>
<li>feat(bearer-auth): make bearerAuth generic for typed context in
verifyToken by <a
href="https://github.com/justinnais"><code>@​justinnais</code></a> in <a
href="https://redirect.github.com/honojs/hono/pull/4913">honojs/hono#4913</a></li>
<li>feat(cache): key cache entries by configured vary headers by <a
href="https://github.com/usualoma"><code>@​usualoma</code></a> in <a
href="https://redirect.github.com/honojs/hono/pull/4915">honojs/hono#4915</a></li>
<li>feat(request): add <code>bytes()</code> by <a
href="https://github.com/yusukebe"><code>@​yusukebe</code></a> in <a
href="https://redirect.github.com/honojs/hono/pull/4921">honojs/hono#4921</a></li>
<li>fix(stream): upgrade <code>@hono/node-server</code> to v2 and fix
abort handling by <a
href="https://github.com/yusukebe"><code>@​yusukebe</code></a> in <a
href="https://redirect.github.com/honojs/hono/pull/4940">honojs/hono#4940</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/justinnais"><code>@​justinnais</code></a> made
their first contribution in <a
href="https://redirect.github.com/honojs/hono/pull/4913">honojs/hono#4913</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/honojs/hono/compare/v4.12.18...v4.12.19">https://github.com/honojs/hono/compare/v4.12.18...v4.12.19</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="7e62bcd22f"><code>7e62bcd</code></a>
4.12.19</li>
<li><a
href="e2f252a874"><code>e2f252a</code></a>
fix(stream): upgrade <code>@hono/node-server</code> to v2 and fix abort
handling (<a
href="https://redirect.github.com/honojs/hono/issues/4940">#4940</a>)</li>
<li><a
href="54f2f0cfda"><code>54f2f0c</code></a>
feat(request): add <code>bytes()</code> (<a
href="https://redirect.github.com/honojs/hono/issues/4921">#4921</a>)</li>
<li><a
href="e59db594fb"><code>e59db59</code></a>
feat(cache): key cache entries by configured vary headers (<a
href="https://redirect.github.com/honojs/hono/issues/4915">#4915</a>)</li>
<li><a
href="48a7ccbc0e"><code>48a7ccb</code></a>
feat(bearer-auth): make bearerAuth generic for typed context in
verifyToken (...</li>
<li><a
href="ff7522fdcc"><code>ff7522f</code></a>
fix(cookie): return the first cookie when there are multiple cookies
with the...</li>
<li><a
href="26f8c33f23"><code>26f8c33</code></a>
fix(serveStatic): make options parameter optional in all adapters (<a
href="https://redirect.github.com/honojs/hono/issues/4934">#4934</a>)</li>
<li><a
href="16c4e3885f"><code>16c4e38</code></a>
ci: pin GitHub Actions to SHAs (<a
href="https://redirect.github.com/honojs/hono/issues/4932">#4932</a>)</li>
<li>See full diff in <a
href="https://github.com/honojs/hono/compare/v4.12.18...v4.12.19">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=hono&package-manager=npm_and_yarn&previous-version=4.12.18&new-version=4.12.19)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-05-16 22:26:23 +02:00
dependabot[bot]
27ca2e5d40 feat(deps): update to claude-agent-sdk 0.3.143 (#664)
Bumps the minor group with 11 updates in the / directory:

| Package | From | To |
| --- | --- | --- |
|
[@agentclientprotocol/sdk](https://github.com/agentclientprotocol/typescript-sdk)
| `0.21.0` | `0.21.1` |
|
[@anthropic-ai/claude-agent-sdk](https://github.com/anthropics/claude-agent-sdk-typescript)
| `0.2.132` | `0.3.143` |
|
[@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node)
| `25.6.0` | `25.8.0` |
|
[@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin)
| `8.59.2` | `8.59.3` |
|
[@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser)
| `8.59.2` | `8.59.3` |
| [eslint](https://github.com/eslint/eslint) | `10.3.0` | `10.4.0` |
|
[vitest](https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest)
| `4.1.5` | `4.1.6` |
| [brace-expansion](https://github.com/juliangruber/brace-expansion) |
`5.0.5` | `5.0.6` |
|
[express-rate-limit](https://github.com/express-rate-limit/express-rate-limit)
| `8.5.1` | `8.5.2` |
| [semver](https://github.com/npm/node-semver) | `7.7.4` | `7.8.0` |
| [type-is](https://github.com/jshttp/type-is) | `2.0.1` | `2.1.0` |


Updates `@agentclientprotocol/sdk` from 0.21.0 to 0.21.1
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/agentclientprotocol/typescript-sdk/releases">@​agentclientprotocol/sdk's
releases</a>.</em></p>
<blockquote>
<h2>v0.21.1</h2>
<h2><a
href="https://github.com/agentclientprotocol/typescript-sdk/compare/v0.21.0...v0.21.1">0.21.1</a>
(2026-05-14)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>emit .js extensions in generated schema barrel for nodenext
consumers (<a
href="https://redirect.github.com/agentclientprotocol/typescript-sdk/issues/146">#146</a>)
(<a
href="63b96db49d">63b96db</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/agentclientprotocol/typescript-sdk/blob/main/CHANGELOG.md">@​agentclientprotocol/sdk's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/agentclientprotocol/typescript-sdk/compare/v0.21.0...v0.21.1">0.21.1</a>
(2026-05-14)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>emit .js extensions in generated schema barrel for nodenext
consumers (<a
href="https://redirect.github.com/agentclientprotocol/typescript-sdk/issues/146">#146</a>)
(<a
href="63b96db49d">63b96db</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="e0099180fe"><code>e009918</code></a>
chore(main): release 0.21.1 (<a
href="https://redirect.github.com/agentclientprotocol/typescript-sdk/issues/147">#147</a>)</li>
<li><a
href="63b96db49d"><code>63b96db</code></a>
fix: emit .js extensions in generated schema barrel for nodenext
consumers (#...</li>
<li><a
href="dfb5692fb0"><code>dfb5692</code></a>
chore(deps): bump crate-ci/typos from 1.46.0 to 1.46.1 (<a
href="https://redirect.github.com/agentclientprotocol/typescript-sdk/issues/144">#144</a>)</li>
<li><a
href="8ca90556b0"><code>8ca9055</code></a>
chore(deps): bump the minor group with 22 updates (<a
href="https://redirect.github.com/agentclientprotocol/typescript-sdk/issues/145">#145</a>)</li>
<li><a
href="7355cdd139"><code>7355cdd</code></a>
chore(deps): bump crate-ci/typos from 1.45.1 to 1.46.0 (<a
href="https://redirect.github.com/agentclientprotocol/typescript-sdk/issues/140">#140</a>)</li>
<li><a
href="0b33b85eba"><code>0b33b85</code></a>
chore(deps): bump the minor group with 20 updates (<a
href="https://redirect.github.com/agentclientprotocol/typescript-sdk/issues/141">#141</a>)</li>
<li><a
href="f017cfaf52"><code>f017cfa</code></a>
chore(deps-dev): bump nanoid from 3.3.11 to 3.3.12 (<a
href="https://redirect.github.com/agentclientprotocol/typescript-sdk/issues/142">#142</a>)</li>
<li>See full diff in <a
href="https://github.com/agentclientprotocol/typescript-sdk/compare/v0.21.0...v0.21.1">compare
view</a></li>
</ul>
</details>
<br />

Updates `@anthropic-ai/claude-agent-sdk` from 0.2.132 to 0.3.143
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/anthropics/claude-agent-sdk-typescript/releases">@​anthropic-ai/claude-agent-sdk's
releases</a>.</em></p>
<blockquote>
<h2>v0.3.143</h2>
<h2>What's changed</h2>
<ul>
<li><code>@anthropic-ai/sdk</code> and
<code>@modelcontextprotocol/sdk</code> are now
<code>peerDependencies</code> instead of <code>dependencies</code>.
Runtime is unaffected (both are bundled); npm/bun/pnpm auto-install
them. yarn classic users should add them explicitly for full TypeScript
type resolution</li>
</ul>
<h2>Update</h2>
<pre lang="sh"><code>npm install @anthropic-ai/claude-agent-sdk@0.3.143
# or
yarn add @anthropic-ai/claude-agent-sdk@0.3.143
# or
pnpm add @anthropic-ai/claude-agent-sdk@0.3.143
# or
bun add @anthropic-ai/claude-agent-sdk@0.3.143
</code></pre>
<h2>v0.3.142</h2>
<h2>What's changed</h2>
<ul>
<li><strong>Breaking:</strong> Removed the v2 session API
(<code>unstable_v2_createSession</code>,
<code>unstable_v2_resumeSession</code>, <code>unstable_v2_prompt</code>,
<code>SDKSession</code>, <code>SDKSessionOptions</code>), deprecated
since 0.2.133. Use <code>query()</code> — pass an
<code>AsyncIterable&lt;SDKUserMessage&gt;</code> for multi-turn, or
<code>options.resume</code> to continue a session.</li>
<li><strong>Breaking:</strong> MCP servers now connect in the background
by default; sessions start immediately and slow servers report
<code>status: &quot;pending&quot;</code> in <code>init</code> until
ready. Set <code>MCP_CONNECTION_NONBLOCKING=0</code> to restore the old
behavior of waiting up to 5s before the first query, or mark a server
<code>alwaysLoad: true</code> to require it in turn 1.</li>
<li><strong>Breaking:</strong> Headless and SDK sessions now use Task
tools (<code>TaskCreate</code> / <code>TaskUpdate</code> /
<code>TaskGet</code> / <code>TaskList</code>) instead of
<code>TodoWrite</code>, deprecated since 0.2.136. Tool consumers should
accumulate by task ID instead of replacing a snapshot list.</li>
<li>Surfaced <code>request_id</code>, <code>subagent_type</code>, and
<code>task_description</code> on SDK message types and task system
events</li>
<li>Headless <code>--sdk-url</code> sessions now exit non-zero with a
stderr diagnostic when the remote transport closes permanently
(401/403/404 or WS permanent close), instead of silently exiting 0</li>
</ul>
<h2>Update</h2>
<pre lang="sh"><code>npm install @anthropic-ai/claude-agent-sdk@0.3.142
# or
yarn add @anthropic-ai/claude-agent-sdk@0.3.142
# or
pnpm add @anthropic-ai/claude-agent-sdk@0.3.142
# or
bun add @anthropic-ai/claude-agent-sdk@0.3.142
</code></pre>
<h2>v0.2.141</h2>
<h2>What's changed</h2>
<ul>
<li><code>TaskCreateInput</code>, <code>TaskCreateOutput</code>,
<code>TaskGetInput</code>, <code>TaskGetOutput</code>,
<code>TaskUpdateInput</code>, <code>TaskUpdateOutput</code>,
<code>TaskListInput</code>, and <code>TaskListOutput</code> types are
now exported from <code>@anthropic-ai/claude-agent-sdk/sdk-tools</code>
and included in the
<code>ToolInputSchemas</code>/<code>ToolOutputSchemas</code> unions</li>
<li>Aligned <code>@anthropic-ai/sdk</code> dependency to ^0.93.0</li>
</ul>
<h2>Update</h2>
<pre lang="sh"><code>npm install @anthropic-ai/claude-agent-sdk@0.2.141
# or
yarn add @anthropic-ai/claude-agent-sdk@0.2.141
&lt;/tr&gt;&lt;/table&gt; 
</code></pre>
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/anthropics/claude-agent-sdk-typescript/blob/main/CHANGELOG.md">@​anthropic-ai/claude-agent-sdk's
changelog</a>.</em></p>
<blockquote>
<h2>0.3.143</h2>
<ul>
<li><code>@anthropic-ai/sdk</code> and
<code>@modelcontextprotocol/sdk</code> are now
<code>peerDependencies</code> instead of <code>dependencies</code>.
Runtime is unaffected (both are bundled); npm/bun/pnpm auto-install
them. yarn classic users should add them explicitly for full TypeScript
type resolution</li>
</ul>
<h2>0.3.142</h2>
<ul>
<li><strong>Breaking:</strong> Removed the v2 session API
(<code>unstable_v2_createSession</code>,
<code>unstable_v2_resumeSession</code>, <code>unstable_v2_prompt</code>,
<code>SDKSession</code>, <code>SDKSessionOptions</code>), deprecated
since 0.2.133. Use <code>query()</code> — pass an
<code>AsyncIterable&lt;SDKUserMessage&gt;</code> for multi-turn, or
<code>options.resume</code> to continue a session.</li>
<li><strong>Breaking:</strong> MCP servers now connect in the background
by default; sessions start immediately and slow servers report
<code>status: &quot;pending&quot;</code> in <code>init</code> until
ready. Set <code>MCP_CONNECTION_NONBLOCKING=0</code> to restore the old
behavior of waiting up to 5s before the first query, or mark a server
<code>alwaysLoad: true</code> to require it in turn 1.</li>
<li><strong>Breaking:</strong> Headless and SDK sessions now use Task
tools (<code>TaskCreate</code> / <code>TaskUpdate</code> /
<code>TaskGet</code> / <code>TaskList</code>) instead of
<code>TodoWrite</code>, deprecated since 0.2.136. Tool consumers should
accumulate by task ID instead of replacing a snapshot list.</li>
<li>Surfaced <code>request_id</code>, <code>subagent_type</code>, and
<code>task_description</code> on SDK message types and task system
events</li>
<li>Headless <code>--sdk-url</code> sessions now exit non-zero with a
stderr diagnostic when the remote transport closes permanently
(401/403/404 or WS permanent close), instead of silently exiting 0</li>
</ul>
<h2>0.2.141</h2>
<ul>
<li><code>TaskCreateInput</code>, <code>TaskCreateOutput</code>,
<code>TaskGetInput</code>, <code>TaskGetOutput</code>,
<code>TaskUpdateInput</code>, <code>TaskUpdateOutput</code>,
<code>TaskListInput</code>, and <code>TaskListOutput</code> types are
now exported from <code>@anthropic-ai/claude-agent-sdk/sdk-tools</code>
and included in the
<code>ToolInputSchemas</code>/<code>ToolOutputSchemas</code> unions</li>
<li>Aligned <code>@anthropic-ai/sdk</code> dependency to ^0.93.0</li>
</ul>
<h2>0.2.140</h2>
<ul>
<li>Updated to parity with Claude Code v2.1.140</li>
</ul>
<h2>0.2.139</h2>
<ul>
<li>Updated to parity with Claude Code v2.1.139</li>
</ul>
<h2>0.2.138</h2>
<ul>
<li>Updated to parity with Claude Code v2.1.138</li>
</ul>
<h2>0.2.137</h2>
<ul>
<li>Updated to parity with Claude Code v2.1.137</li>
</ul>
<h2>0.2.136</h2>
<ul>
<li>Added <code>resolveSettings()</code> (alpha) to inspect effective
merged settings without spawning the Claude CLI; reads MDM
(plist/HKLM/HKCU) for parity with CLI startup</li>
<li>Deprecated <code>TodoWrite</code> tool — future versions will switch
to Task tools (<code>TaskCreate</code>, <code>TaskGet</code>,
<code>TaskUpdate</code>, <code>TaskList</code>)</li>
</ul>
<h2>0.2.135</h2>
<ul>
<li>Updated to parity with Claude Code v2.1.135</li>
</ul>
<h2>0.2.134</h2>
<ul>
<li>Updated to parity with Claude Code v2.1.134</li>
</ul>
<h2>0.2.133</h2>
<ul>
<li>Deprecated the unstable V2 session API
(<code>unstable_v2_createSession</code> /
<code>unstable_v2_resumeSession</code> /
<code>unstable_v2_prompt</code>) — use <code>query()</code> instead</li>
<li>Deprecated passing <code>'Skill'</code> in <code>allowedTools</code>
— use the <code>skills</code> option instead</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="fa5d004c65"><code>fa5d004</code></a>
chore: Update CHANGELOG.md</li>
<li><a
href="dcac1633cc"><code>dcac163</code></a>
chore: Update CHANGELOG.md</li>
<li><a
href="b6d0490791"><code>b6d0490</code></a>
chore: Update CHANGELOG.md</li>
<li><a
href="b14b7c97ff"><code>b14b7c9</code></a>
chore: Update CHANGELOG.md</li>
<li><a
href="ee3fe61081"><code>ee3fe61</code></a>
chore: Update CHANGELOG.md</li>
<li><a
href="1d9038531e"><code>1d90385</code></a>
chore: Update CHANGELOG.md</li>
<li><a
href="8d0a9588e6"><code>8d0a958</code></a>
Pin GitHub Actions to commit SHAs (<a
href="https://redirect.github.com/anthropics/claude-agent-sdk-typescript/issues/320">#320</a>)</li>
<li><a
href="3ccbe544fd"><code>3ccbe54</code></a>
chore: Update CHANGELOG.md</li>
<li><a
href="de7d6c1a35"><code>de7d6c1</code></a>
chore: Update CHANGELOG.md</li>
<li><a
href="1b3ab7bd01"><code>1b3ab7b</code></a>
chore: Update CHANGELOG.md</li>
<li>See full diff in <a
href="https://github.com/anthropics/claude-agent-sdk-typescript/compare/v0.2.132...v0.3.143">compare
view</a></li>
</ul>
</details>
<br />

Updates `@types/node` from 25.6.0 to 25.8.0
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node">compare
view</a></li>
</ul>
</details>
<br />

Updates `@typescript-eslint/eslint-plugin` from 8.59.2 to 8.59.3
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/typescript-eslint/typescript-eslint/releases">@​typescript-eslint/eslint-plugin's
releases</a>.</em></p>
<blockquote>
<h2>v8.59.3</h2>
<h2>8.59.3 (2026-05-11)</h2>
<p>This was a version bump only, there were no code changes.</p>
<p>See <a
href="https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.59.3">GitHub
Releases</a> for more information.</p>
<p>You can read about our <a
href="https://typescript-eslint.io/users/versioning">versioning
strategy</a> and <a
href="https://typescript-eslint.io/users/releases">releases</a> on our
website.</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/CHANGELOG.md">@​typescript-eslint/eslint-plugin's
changelog</a>.</em></p>
<blockquote>
<h2>8.59.3 (2026-05-11)</h2>
<p>This was a version bump only for eslint-plugin to align it with other
projects, there were no code changes.</p>
<p>See <a
href="https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.59.3">GitHub
Releases</a> for more information.</p>
<p>You can read about our <a
href="https://typescript-eslint.io/users/versioning">versioning
strategy</a> and <a
href="https://typescript-eslint.io/users/releases">releases</a> on our
website.</p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="48e13c0261"><code>48e13c0</code></a>
chore(release): publish 8.59.3</li>
<li><a
href="e26dc8003a"><code>e26dc80</code></a>
docs: update stale links to latest (<a
href="https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin/issues/12313">#12313</a>)</li>
<li><a
href="44f9625336"><code>44f9625</code></a>
chore(deps): update vitest monorepo to v4.1.5 (<a
href="https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin/issues/12307">#12307</a>)</li>
<li>See full diff in <a
href="https://github.com/typescript-eslint/typescript-eslint/commits/v8.59.3/packages/eslint-plugin">compare
view</a></li>
</ul>
</details>
<br />

Updates `@typescript-eslint/parser` from 8.59.2 to 8.59.3
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/typescript-eslint/typescript-eslint/releases">@​typescript-eslint/parser's
releases</a>.</em></p>
<blockquote>
<h2>v8.59.3</h2>
<h2>8.59.3 (2026-05-11)</h2>
<p>This was a version bump only, there were no code changes.</p>
<p>See <a
href="https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.59.3">GitHub
Releases</a> for more information.</p>
<p>You can read about our <a
href="https://typescript-eslint.io/users/versioning">versioning
strategy</a> and <a
href="https://typescript-eslint.io/users/releases">releases</a> on our
website.</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/parser/CHANGELOG.md">@​typescript-eslint/parser's
changelog</a>.</em></p>
<blockquote>
<h2>8.59.3 (2026-05-11)</h2>
<p>This was a version bump only for parser to align it with other
projects, there were no code changes.</p>
<p>See <a
href="https://github.com/typescript-eslint/typescript-eslint/releases/tag/v8.59.3">GitHub
Releases</a> for more information.</p>
<p>You can read about our <a
href="https://typescript-eslint.io/users/versioning">versioning
strategy</a> and <a
href="https://typescript-eslint.io/users/releases">releases</a> on our
website.</p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="48e13c0261"><code>48e13c0</code></a>
chore(release): publish 8.59.3</li>
<li><a
href="44f9625336"><code>44f9625</code></a>
chore(deps): update vitest monorepo to v4.1.5 (<a
href="https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser/issues/12307">#12307</a>)</li>
<li>See full diff in <a
href="https://github.com/typescript-eslint/typescript-eslint/commits/v8.59.3/packages/parser">compare
view</a></li>
</ul>
</details>
<br />

Updates `eslint` from 10.3.0 to 10.4.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/eslint/eslint/releases">eslint's
releases</a>.</em></p>
<blockquote>
<h2>v10.4.0</h2>
<h2>Features</h2>
<ul>
<li><a
href="1a45ec596a"><code>1a45ec5</code></a>
feat: check sequence expressions in <code>for-direction</code> (<a
href="https://redirect.github.com/eslint/eslint/issues/20701">#20701</a>)
(kuldeep kumar)</li>
<li><a
href="450040bd89"><code>450040b</code></a>
feat: add <code>includeIgnoreFile()</code> to <code>eslint/config</code>
(<a
href="https://redirect.github.com/eslint/eslint/issues/20735">#20735</a>)
(Kirk Waiblinger)</li>
</ul>
<h2>Bug Fixes</h2>
<ul>
<li><a
href="544c0c3da5"><code>544c0c3</code></a>
fix: escape code path DOT labels in debug output (<a
href="https://redirect.github.com/eslint/eslint/issues/20866">#20866</a>)
(Pixel998)</li>
<li><a
href="6799431203"><code>6799431</code></a>
fix: update dependency <code>@​eslint/config-helpers</code> to ^0.6.0
(<a
href="https://redirect.github.com/eslint/eslint/issues/20850">#20850</a>)
(renovate[bot])</li>
<li><a
href="f078fef500"><code>f078fef</code></a>
fix: handle non-array deprecated rule replacements (<a
href="https://redirect.github.com/eslint/eslint/issues/20825">#20825</a>)
(xbinaryx)</li>
</ul>
<h2>Documentation</h2>
<ul>
<li><a
href="7e52a7151f"><code>7e52a71</code></a>
docs: add mention of <code>@eslint-react/eslint-plugin</code> (<a
href="https://redirect.github.com/eslint/eslint/issues/20869">#20869</a>)
(Pavel)</li>
<li><a
href="db3468ba74"><code>db3468b</code></a>
docs: tweak wording around ambiguous CJS-vs-ESM config (<a
href="https://redirect.github.com/eslint/eslint/issues/20865">#20865</a>)
(Kirk Waiblinger)</li>
<li><a
href="90846643ec"><code>9084664</code></a>
docs: Update README (GitHub Actions Bot)</li>
<li><a
href="9cc7387504"><code>9cc7387</code></a>
docs: Update README (GitHub Actions Bot)</li>
<li><a
href="3d7b548440"><code>3d7b548</code></a>
docs: Update README (GitHub Actions Bot)</li>
<li><a
href="191ec3c0a3"><code>191ec3c</code></a>
docs: Update README (GitHub Actions Bot)</li>
</ul>
<h2>Chores</h2>
<ul>
<li><a
href="6616856f28"><code>6616856</code></a>
chore: upgrade knip to v6 (<a
href="https://redirect.github.com/eslint/eslint/issues/20875">#20875</a>)
(Pixel998)</li>
<li><a
href="d13b084a3a"><code>d13b084</code></a>
ci: ensure auto-created PRs run CI (<a
href="https://redirect.github.com/eslint/eslint/issues/20860">#20860</a>)
(lumir)</li>
<li><a
href="e71c7af86d"><code>e71c7af</code></a>
ci: bump pnpm/action-setup from 6.0.5 to 6.0.7 (<a
href="https://redirect.github.com/eslint/eslint/issues/20862">#20862</a>)
(dependabot[bot])</li>
<li><a
href="d84393dea1"><code>d84393d</code></a>
test: add unit tests for SuppressionsService.applySuppressions() (<a
href="https://redirect.github.com/eslint/eslint/issues/20863">#20863</a>)
(kuldeep kumar)</li>
<li><a
href="24db8cb8e6"><code>24db8cb</code></a>
test: add tests for SuppressionsService.save() (<a
href="https://redirect.github.com/eslint/eslint/issues/20802">#20802</a>)
(kuldeep kumar)</li>
<li><a
href="2ef0549cac"><code>2ef0549</code></a>
chore: update ecosystem plugins (<a
href="https://redirect.github.com/eslint/eslint/issues/20857">#20857</a>)
(github-actions[bot])</li>
<li><a
href="a4297918d2"><code>a429791</code></a>
ci: remove <code>eslint-webpack-plugin</code> types integration test (<a
href="https://redirect.github.com/eslint/eslint/issues/20668">#20668</a>)
(Milos Djermanovic)</li>
<li><a
href="9e37386aa7"><code>9e37386</code></a>
chore: replace <code>recast</code> with range approach in
code-sample-minimizer (<a
href="https://redirect.github.com/eslint/eslint/issues/20682">#20682</a>)
(Copilot)</li>
<li><a
href="0dd1f9ffc9"><code>0dd1f9f</code></a>
test: disable warning for
<code>vm.constants.USE_MAIN_CONTEXT_DEFAULT_LOADER</code> (<a
href="https://redirect.github.com/eslint/eslint/issues/20845">#20845</a>)
(Francesco Trotta)</li>
<li><a
href="9da3c7bc92"><code>9da3c7b</code></a>
refactor: remove deprecated <code>meta.language</code> and migrate
<code>meta.dialects</code> (<a
href="https://redirect.github.com/eslint/eslint/issues/20716">#20716</a>)
(Pixel998)</li>
<li><a
href="2099ed12a0"><code>2099ed1</code></a>
refactor: add <code>meta.defaultOptions</code> to more rules, enable
linting (<a
href="https://redirect.github.com/eslint/eslint/issues/20800">#20800</a>)
(xbinaryx)</li>
<li><a
href="f1dfbc9ca5"><code>f1dfbc9</code></a>
chore: update ecosystem plugins (<a
href="https://redirect.github.com/eslint/eslint/issues/20836">#20836</a>)
(github-actions[bot])</li>
<li><a
href="c75941390c"><code>c759413</code></a>
ci: bump pnpm/action-setup from 6.0.3 to 6.0.5 (<a
href="https://redirect.github.com/eslint/eslint/issues/20843">#20843</a>)
(dependabot[bot])</li>
<li><a
href="5b817d6fdc"><code>5b817d6</code></a>
test: add unit tests for lib/shared/ast-utils (<a
href="https://redirect.github.com/eslint/eslint/issues/20838">#20838</a>)
(kuldeep kumar)</li>
<li><a
href="1c13ae3934"><code>1c13ae3</code></a>
test: add unit tests for lib/shared/severity (<a
href="https://redirect.github.com/eslint/eslint/issues/20835">#20835</a>)
(kuldeep kumar)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="452c4010c0"><code>452c401</code></a>
10.4.0</li>
<li><a
href="b6417e8b55"><code>b6417e8</code></a>
Build: changelog update for 10.4.0</li>
<li><a
href="6616856f28"><code>6616856</code></a>
chore: upgrade knip to v6 (<a
href="https://redirect.github.com/eslint/eslint/issues/20875">#20875</a>)</li>
<li><a
href="d13b084a3a"><code>d13b084</code></a>
ci: ensure auto-created PRs run CI (<a
href="https://redirect.github.com/eslint/eslint/issues/20860">#20860</a>)</li>
<li><a
href="7e52a7151f"><code>7e52a71</code></a>
docs: add mention of <code>@eslint-react/eslint-plugin</code> (<a
href="https://redirect.github.com/eslint/eslint/issues/20869">#20869</a>)</li>
<li><a
href="e71c7af86d"><code>e71c7af</code></a>
ci: bump pnpm/action-setup from 6.0.5 to 6.0.7 (<a
href="https://redirect.github.com/eslint/eslint/issues/20862">#20862</a>)</li>
<li><a
href="544c0c3da5"><code>544c0c3</code></a>
fix: escape code path DOT labels in debug output (<a
href="https://redirect.github.com/eslint/eslint/issues/20866">#20866</a>)</li>
<li><a
href="db3468ba74"><code>db3468b</code></a>
docs: tweak wording around ambiguous CJS-vs-ESM config (<a
href="https://redirect.github.com/eslint/eslint/issues/20865">#20865</a>)</li>
<li><a
href="d84393dea1"><code>d84393d</code></a>
test: add unit tests for SuppressionsService.applySuppressions() (<a
href="https://redirect.github.com/eslint/eslint/issues/20863">#20863</a>)</li>
<li><a
href="90846643ec"><code>9084664</code></a>
docs: Update README</li>
<li>Additional commits viewable in <a
href="https://github.com/eslint/eslint/compare/v10.3.0...v10.4.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `vitest` from 4.1.5 to 4.1.6
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/vitest-dev/vitest/releases">vitest's
releases</a>.</em></p>
<blockquote>
<h2>v4.1.6</h2>
<h3>   🐞 Bug Fixes</h3>
<ul>
<li><strong>browser</strong>: Provide project reference in
<code>ToMatchScreenshotResolvePath</code>  -  by <a
href="https://github.com/macarie"><code>@​macarie</code></a> and <a
href="https://github.com/sheremet-va"><code>@​sheremet-va</code></a> in
<a
href="https://redirect.github.com/vitest-dev/vitest/issues/10138">vitest-dev/vitest#10138</a>
<a href="https://github.com/vitest-dev/vitest/commit/31882607c"><!-- raw
HTML omitted -->(31882)<!-- raw HTML omitted --></a></li>
<li>Global <code>sequence.concurrent: true</code> with top-level
<code>test(..., { concurrent: false })</code> + depreacte
<code>sequential</code> test API and options  -  by <a
href="https://github.com/hi-ogawa"><code>@​hi-ogawa</code></a>,
<strong>Codex</strong> and <a
href="https://github.com/sheremet-va"><code>@​sheremet-va</code></a> in
<a
href="https://redirect.github.com/vitest-dev/vitest/issues/10196">vitest-dev/vitest#10196</a>
<a href="https://github.com/vitest-dev/vitest/commit/2847dfa2a"><!-- raw
HTML omitted -->(2847d)<!-- raw HTML omitted --></a></li>
<li><strong>browser</strong>: Simplify orchestrator otel carrier  -  by
<a href="https://github.com/hi-ogawa"><code>@​hi-ogawa</code></a> in <a
href="https://redirect.github.com/vitest-dev/vitest/issues/10285">vitest-dev/vitest#10285</a>
<a href="https://github.com/vitest-dev/vitest/commit/18af98cee"><!-- raw
HTML omitted -->(18af9)<!-- raw HTML omitted --></a></li>
</ul>
<h3>   🏎 Performance</h3>
<ul>
<li>Stringify diff objects only once  -  by <a
href="https://github.com/sheremet-va"><code>@​sheremet-va</code></a> in
<a
href="https://redirect.github.com/vitest-dev/vitest/issues/10276">vitest-dev/vitest#10276</a>
<a href="https://github.com/vitest-dev/vitest/commit/9f7b1528c"><!-- raw
HTML omitted -->(9f7b1)<!-- raw HTML omitted --></a></li>
</ul>
<h5>    <a
href="https://github.com/vitest-dev/vitest/compare/v4.1.5...v4.1.6">View
changes on GitHub</a></h5>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="a8fd24c1ca"><code>a8fd24c</code></a>
chore: release v4.1.6</li>
<li><a
href="18af98cee1"><code>18af98c</code></a>
fix(browser): simplify orchestrator otel carrier (<a
href="https://github.com/vitest-dev/vitest/tree/HEAD/packages/vitest/issues/10285">#10285</a>)</li>
<li><a
href="31882607cc"><code>3188260</code></a>
feat(browser): provide project reference in
<code>ToMatchScreenshotResolvePath</code> (#...</li>
<li>See full diff in <a
href="https://github.com/vitest-dev/vitest/commits/v4.1.6/packages/vitest">compare
view</a></li>
</ul>
</details>
<br />

Updates `@anthropic-ai/claude-agent-sdk-darwin-arm64` from 0.2.132 to
0.3.143

Updates `@anthropic-ai/claude-agent-sdk-darwin-x64` from 0.2.132 to
0.3.143

Updates `@anthropic-ai/claude-agent-sdk-linux-arm64` from 0.2.132 to
0.3.143

Updates `@anthropic-ai/claude-agent-sdk-linux-arm64-musl` from 0.2.132
to 0.3.143

Updates `@anthropic-ai/claude-agent-sdk-linux-x64` from 0.2.132 to
0.3.143

Updates `@anthropic-ai/claude-agent-sdk-linux-x64-musl` from 0.2.132 to
0.3.143

Updates `@anthropic-ai/claude-agent-sdk-win32-arm64` from 0.2.132 to
0.3.143

Updates `@anthropic-ai/claude-agent-sdk-win32-x64` from 0.2.132 to
0.3.143

Updates `@eslint/config-helpers` from 0.5.5 to 0.6.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/eslint/rewrite/releases">@​eslint/config-helpers's
releases</a>.</em></p>
<blockquote>
<h2>plugin-kit: v0.6.0</h2>
<h2><a
href="https://github.com/eslint/rewrite/compare/plugin-kit-v0.5.1...plugin-kit-v0.6.0">0.6.0</a>
(2026-01-29)</h2>
<h3>Features</h3>
<ul>
<li>add <code>CustomRuleVisitorWithExit</code> type to
<code>@eslint/plugin-kit</code> (<a
href="https://redirect.github.com/eslint/rewrite/issues/351">#351</a>)
(<a
href="e7d1be4066">e7d1be4</a>)</li>
<li>Add custom rule type helpers to <code>@eslint/plugin-kit</code> (<a
href="https://redirect.github.com/eslint/rewrite/issues/355">#355</a>)
(<a
href="8ac853046a">8ac8530</a>)</li>
</ul>
<h3>Dependencies</h3>
<ul>
<li>The following workspace dependencies were updated
<ul>
<li>dependencies
<ul>
<li><code>@​eslint/core</code> bumped from ^1.0.1 to ^1.1.0</li>
</ul>
</li>
</ul>
</li>
</ul>
<h2>config-helpers: v0.6.0</h2>
<h2><a
href="https://github.com/eslint/rewrite/compare/config-helpers-v0.5.5...config-helpers-v0.6.0">0.6.0</a>
(2026-05-08)</h2>
<h3>Features</h3>
<ul>
<li>Add new <code>includeIgnoreFile()</code> to config-helpers (<a
href="https://redirect.github.com/eslint/rewrite/issues/430">#430</a>)
(<a
href="9b51352902">9b51352</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/eslint/rewrite/blob/main/packages/config-helpers/CHANGELOG.md">@​eslint/config-helpers's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/eslint/rewrite/compare/config-helpers-v0.5.5...config-helpers-v0.6.0">0.6.0</a>
(2026-05-08)</h2>
<h3>Features</h3>
<ul>
<li>Add new <code>includeIgnoreFile()</code> to config-helpers (<a
href="https://redirect.github.com/eslint/rewrite/issues/430">#430</a>)
(<a
href="9b51352902">9b51352</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/eslint/rewrite/commits/core-v0.6.0/packages/config-helpers">compare
view</a></li>
</ul>
</details>
<br />

Updates `@oxc-project/types` from 0.128.0 to 0.130.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/oxc-project/oxc/releases">@​oxc-project/types's
releases</a>.</em></p>
<blockquote>
<h2>oxc crates_v0.130.0</h2>
<h3>🚀 Features</h3>
<ul>
<li>66c9b01 transformer/typescript: Debug_assert that
<code>enum_eval</code> ran in semantic (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22252">#22252</a>)
(Dunqing)</li>
<li>ffe6475 minifier: Fold <code>Array</code> constructor with safe
spreads (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22215">#22215</a>)
(camc314)</li>
</ul>
<h3>🐛 Bug Fixes</h3>
<ul>
<li>d3d0b18 traverse: Handle
<code>ChainElement::TSNonNullExpression</code> in
<code>GatherNodeParts</code> (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22247">#22247</a>)
(leaysgur)</li>
<li>4e880de transformer/object-rest-spread: Declare temp vars for
computed keys (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22284">#22284</a>)
(camc314)</li>
<li>a7c3e22 semantic: Clear member write target for computed keys (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22302">#22302</a>)
(camc314)</li>
<li>6a8852d codegen: Emit newline after legal-comment orphan flush (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22304">#22304</a>)
(Dunqing)</li>
<li>5da9fda transformer/explicit-resource-management: Preserve class
names (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22306">#22306</a>)
(Dunqing)</li>
<li>b5d970f transformer/explicit-resource-management: Preserve class
names (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22290">#22290</a>)
(camc314)</li>
<li>bc54fd4 minifier: Keep function / class names if direct eval is
present in the scope (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22241">#22241</a>)
(sapphi-red)</li>
<li>7a810c0 minifier: Refresh direct eval flags after DCE (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21787">#21787</a>)
(Dunqing)</li>
<li>dd88726 transformer/legacy-decorator: Preserve accessor type
annotation for emitDecoratorMetadata (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21966">#21966</a>)
(Dunqing)</li>
<li>29a3cd7 codegen: Swap mapping/indent order for top-level decls (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22206">#22206</a>)
(Dunqing)</li>
<li>73b4f40 minifier: Preserve catch binding with direct eval (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22221">#22221</a>)
(camc314)</li>
<li>0e13d17 minifier: Preserve optional chain base side effects (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22219">#22219</a>)
(camc314)</li>
<li>0c7c01c transformer/typescript: Inline optional-chain enum member
access (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21834">#21834</a>)
(Dunqing)</li>
<li>a6aff7e codegen: Emit block/array/object end mapping at close char
(<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22200">#22200</a>)
(Dunqing)</li>
<li>a099b03 codegen: Emit call end mapping at <code>)</code> position,
not past it (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22199">#22199</a>)
(Dunqing)</li>
<li>5753774 minifier: Cap if-return ternary collapse for firefox (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21841">#21841</a>)
(Gurupungav Narayanan)</li>
<li>2493bdd codegen: Correct sourcemap end mappings for closing
delimiters (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22001">#22001</a>)
(Mark Dalgleish)</li>
<li>3b385e2 minifier: Bail optimizing <code>Array</code> with unknown
arg count (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22188">#22188</a>)
(camc314)</li>
<li>9fa2122 parser: Parse array computed class keys (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22159">#22159</a>)
(camc314)</li>
</ul>
<h3>📚 Documentation</h3>
<ul>
<li>a4a6892 napi/parser: Correct code comment (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22278">#22278</a>)
(overlookmotel)</li>
<li>9305373 oxc: Update README (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22178">#22178</a>)
(camc314)</li>
</ul>
<h2>oxc crates_v0.129.0</h2>
<h3>💥 BREAKING CHANGES</h3>
<ul>
<li>0ffbe0d allocator: [<strong>BREAKING</strong>] Remove
<code>Allocator::end_ptr</code> method (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21871">#21871</a>)
(overlookmotel)</li>
</ul>
<h3>🚀 Features</h3>
<ul>
<li>9593ec8 transformer/jsx: Add jsxDEV source metadata for fragments
(<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21932">#21932</a>)
(Ido Rosenthal)</li>
</ul>
<h3>🐛 Bug Fixes</h3>
<ul>
<li>81e834c parser: Prevent multiple <code>Parser</code> instances in
binary (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22120">#22120</a>)
(overlookmotel)</li>
<li>429deac napi/parser: Export <code>visitorKeys</code> from
<code>wasm</code> entrypoint (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21996">#21996</a>)
(NullVoxPopuli)</li>
<li>e852911 codegen: Preserve legal comments orphaned by upstream passes
(<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21575">#21575</a>)
(Dunqing)</li>
<li>e3399ec transformer/class-properties: Preserve RHS in
logical-assignment to static private field (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21950">#21950</a>)
(Dunqing)</li>
<li>c59c199 transformer/typescript: Emit class fields for parameter
properties (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21831">#21831</a>)
(Dunqing)</li>
<li>aaabde4 parser: Attach legal comments to following token (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/21670">#21670</a>)
(Dunqing)</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="650417ffd0"><code>650417f</code></a>
release(crates): oxc v0.130.0 (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22316">#22316</a>)</li>
<li><a
href="ec00055e64"><code>ec00055</code></a>
release(crates): oxc v0.129.0 (<a
href="https://github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types/issues/22108">#22108</a>)</li>
<li>See full diff in <a
href="https://github.com/oxc-project/oxc/commits/crates_v0.130.0/npm/oxc-types">compare
view</a></li>
</ul>
</details>
<br />

Updates `@rolldown/binding-android-arm64` from 1.0.0-rc.18 to 1.0.1
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rolldown/rolldown/releases">@​rolldown/binding-android-arm64's
releases</a>.</em></p>
<blockquote>
<h2>v1.0.1</h2>
<h2>[1.0.1] - 2026-05-13</h2>
<h3>🚀 Features</h3>
<ul>
<li>experimental/lazy-barrel: advice on oversized barrel modules (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9236">#9236</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>rolldown: inline optional-chain enum access (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9379">#9379</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>chunk-optimization: dedupe already-loaded dynamic deps (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9305">#9305</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
<li>binding: call moduleParsed hook in ParallelJsPlugin (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9318">#9318</a>)
by <a href="https://github.com/jaehafe"><code>@​jaehafe</code></a></li>
</ul>
<h3>🐛 Bug Fixes</h3>
<ul>
<li>transform: enable <code>enum_eval</code> for
<code>transformSync</code> and vite TS transform (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9325">#9325</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>error: remove severity prefix from diagnostic messages (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9262">#9262</a>)
by <a
href="https://github.com/Kyujenius"><code>@​Kyujenius</code></a></li>
<li>deps: pin pnpm to 10.23.0 to work around catalog mismatch on Netlify
(<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9364">#9364</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>ci: pin mimalloc-safe to 0.1.58 (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9361">#9361</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>dev/lazy: fix exports of lazy requests in lazy chunks (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9249">#9249</a>)
by <a href="https://github.com/h-a-n-a"><code>@​h-a-n-a</code></a></li>
<li>rolldown_plugin_vite_resolve: handle errors in
<code>resolveSubpathImports</code> callback (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9355">#9355</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>rolldown_plugin_lazy_compilation: use loadExports for fetched proxy
to preserve original export names (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9132">#9132</a>)
by <a href="https://github.com/h-a-n-a"><code>@​h-a-n-a</code></a></li>
<li>common: include offending index in HybridIndexVec panic message (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9296">#9296</a>)
by <a href="https://github.com/SAY-5"><code>@​SAY-5</code></a></li>
</ul>
<h3>🚜 Refactor</h3>
<ul>
<li>ecmascript: extract semantic_builder_for_transform helper (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9326">#9326</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>test: extract reusable static-import-cycle helper (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9332">#9332</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
</ul>
<h3>📚 Documentation</h3>
<ul>
<li>clarify scope of <code>topLevelVar</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9380">#9380</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
<li>meta/design: add ast-mutation design doc (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9338">#9338</a>)
by <a href="https://github.com/hyf0"><code>@​hyf0</code></a></li>
<li>feat: add ai policy in contribution guide (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9315">#9315</a>)
by <a
href="https://github.com/mdong1909"><code>@​mdong1909</code></a></li>
</ul>
<h3>⚡ Performance</h3>
<ul>
<li>binding: enable mimalloc v3 to reduce idle memory (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9349">#9349</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
</ul>
<h3>🧪 Testing</h3>
<ul>
<li>mcs: cover require() in <code>$initial</code> group (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9376">#9376</a>)
by <a href="https://github.com/hyf0"><code>@​hyf0</code></a></li>
<li>add regression for CJS facade chunk merge into entry (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9351">#9351</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
</ul>
<h3>⚙️ Miscellaneous Tasks</h3>
<ul>
<li>switch prepare-release to manual dispatch with version input (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9383">#9383</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>migrate <code>@rolldown/pluginutils</code> to
<code>rolldown/plugins</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9317">#9317</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>deps: pin libmimalloc-sys2 to 0.1.54 (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9372">#9372</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>replace <code>igorskyflyer/action-readfile</code> with
<code>cat</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9369">#9369</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>deps: update test262 submodule for tests (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9371">#9371</a>)
by <a
href="https://github.com/rolldown-guard"><code>@​rolldown-guard</code></a>[bot]</li>
<li>use app token for test dep update PRs (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9368">#9368</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>replace some actions with gh commands (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9367">#9367</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rolldown/rolldown/blob/main/CHANGELOG.md">@​rolldown/binding-android-arm64's
changelog</a>.</em></p>
<blockquote>
<h2>[1.0.1] - 2026-05-13</h2>
<h3>🚀 Features</h3>
<ul>
<li>experimental/lazy-barrel: advice on oversized barrel modules (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9236">#9236</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>rolldown: inline optional-chain enum access (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9379">#9379</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>chunk-optimization: dedupe already-loaded dynamic deps (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9305">#9305</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
<li>binding: call moduleParsed hook in ParallelJsPlugin (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9318">#9318</a>)
by <a href="https://github.com/jaehafe"><code>@​jaehafe</code></a></li>
</ul>
<h3>🐛 Bug Fixes</h3>
<ul>
<li>transform: enable <code>enum_eval</code> for
<code>transformSync</code> and vite TS transform (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9325">#9325</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>error: remove severity prefix from diagnostic messages (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9262">#9262</a>)
by <a
href="https://github.com/Kyujenius"><code>@​Kyujenius</code></a></li>
<li>deps: pin pnpm to 10.23.0 to work around catalog mismatch on Netlify
(<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9364">#9364</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>ci: pin mimalloc-safe to 0.1.58 (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9361">#9361</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>dev/lazy: fix exports of lazy requests in lazy chunks (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9249">#9249</a>)
by <a href="https://github.com/h-a-n-a"><code>@​h-a-n-a</code></a></li>
<li>rolldown_plugin_vite_resolve: handle errors in
<code>resolveSubpathImports</code> callback (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9355">#9355</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>rolldown_plugin_lazy_compilation: use loadExports for fetched proxy
to preserve original export names (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9132">#9132</a>)
by <a href="https://github.com/h-a-n-a"><code>@​h-a-n-a</code></a></li>
<li>common: include offending index in HybridIndexVec panic message (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9296">#9296</a>)
by <a href="https://github.com/SAY-5"><code>@​SAY-5</code></a></li>
</ul>
<h3>🚜 Refactor</h3>
<ul>
<li>ecmascript: extract semantic_builder_for_transform helper (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9326">#9326</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>test: extract reusable static-import-cycle helper (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9332">#9332</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
</ul>
<h3>📚 Documentation</h3>
<ul>
<li>clarify scope of <code>topLevelVar</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9380">#9380</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
<li>meta/design: add ast-mutation design doc (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9338">#9338</a>)
by <a href="https://github.com/hyf0"><code>@​hyf0</code></a></li>
<li>feat: add ai policy in contribution guide (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9315">#9315</a>)
by <a
href="https://github.com/mdong1909"><code>@​mdong1909</code></a></li>
</ul>
<h3>⚡ Performance</h3>
<ul>
<li>binding: enable mimalloc v3 to reduce idle memory (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9349">#9349</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
</ul>
<h3>🧪 Testing</h3>
<ul>
<li>mcs: cover require() in <code>$initial</code> group (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9376">#9376</a>)
by <a href="https://github.com/hyf0"><code>@​hyf0</code></a></li>
<li>add regression for CJS facade chunk merge into entry (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9351">#9351</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
</ul>
<h3>⚙️ Miscellaneous Tasks</h3>
<ul>
<li>switch prepare-release to manual dispatch with version input (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9383">#9383</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>migrate <code>@rolldown/pluginutils</code> to
<code>rolldown/plugins</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9317">#9317</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>deps: pin libmimalloc-sys2 to 0.1.54 (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9372">#9372</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>replace <code>igorskyflyer/action-readfile</code> with
<code>cat</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9369">#9369</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>deps: update test262 submodule for tests (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9371">#9371</a>)
by <a
href="https://github.com/rolldown-guard"><code>@​rolldown-guard</code></a>[bot]</li>
<li>use app token for test dep update PRs (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9368">#9368</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>replace some actions with gh commands (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9367">#9367</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>replace action-semantic-pull-request with inline regex (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9366">#9366</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="27779450b5"><code>2777945</code></a>
release: v1.0.1 (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9384">#9384</a>)</li>
<li><a
href="4e353804a3"><code>4e35380</code></a>
feat(experimental/lazy-barrel): advice on oversized barrel modules (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9236">#9236</a>)</li>
<li><a
href="83d2762658"><code>83d2762</code></a>
docs: clarify scope of <code>topLevelVar</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9380">#9380</a>)</li>
<li><a
href="9ba2e73935"><code>9ba2e73</code></a>
chore: migrate <code>@rolldown/pluginutils</code> to
<code>rolldown/plugins</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9317">#9317</a>)</li>
<li><a
href="ef5796f0ec"><code>ef5796f</code></a>
fix(transform): enable <code>enum_eval</code> for
<code>transformSync</code> and vite TS transform ...</li>
<li><a
href="1f5dce1dc8"><code>1f5dce1</code></a>
fix(error): remove severity prefix from diagnostic messages (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9262">#9262</a>)</li>
<li><a
href="fd479191a9"><code>fd47919</code></a>
chore(deps): upgrade oxc to 0.130.0 (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9360">#9360</a>)</li>
<li><a
href="4c121d30d1"><code>4c121d3</code></a>
chore(deps): update npm packages (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9343">#9343</a>)</li>
<li><a
href="024de36969"><code>024de36</code></a>
fix(rolldown_plugin_vite_resolve): handle errors in
<code>resolveSubpathImports</code> c...</li>
<li><a
href="7e5855c336"><code>7e5855c</code></a>
feat(chunk-optimization): dedupe already-loaded dynamic deps (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9305">#9305</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/rolldown/rolldown/commits/v1.0.1/packages/rolldown">compare
view</a></li>
</ul>
</details>
<br />

Updates `@rolldown/binding-darwin-arm64` from 1.0.0-rc.18 to 1.0.1
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rolldown/rolldown/releases">@​rolldown/binding-darwin-arm64's
releases</a>.</em></p>
<blockquote>
<h2>v1.0.1</h2>
<h2>[1.0.1] - 2026-05-13</h2>
<h3>🚀 Features</h3>
<ul>
<li>experimental/lazy-barrel: advice on oversized barrel modules (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9236">#9236</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>rolldown: inline optional-chain enum access (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9379">#9379</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>chunk-optimization: dedupe already-loaded dynamic deps (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9305">#9305</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
<li>binding: call moduleParsed hook in ParallelJsPlugin (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9318">#9318</a>)
by <a href="https://github.com/jaehafe"><code>@​jaehafe</code></a></li>
</ul>
<h3>🐛 Bug Fixes</h3>
<ul>
<li>transform: enable <code>enum_eval</code> for
<code>transformSync</code> and vite TS transform (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9325">#9325</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>error: remove severity prefix from diagnostic messages (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9262">#9262</a>)
by <a
href="https://github.com/Kyujenius"><code>@​Kyujenius</code></a></li>
<li>deps: pin pnpm to 10.23.0 to work around catalog mismatch on Netlify
(<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9364">#9364</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>ci: pin mimalloc-safe to 0.1.58 (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9361">#9361</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>dev/lazy: fix exports of lazy requests in lazy chunks (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9249">#9249</a>)
by <a href="https://github.com/h-a-n-a"><code>@​h-a-n-a</code></a></li>
<li>rolldown_plugin_vite_resolve: handle errors in
<code>resolveSubpathImports</code> callback (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9355">#9355</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>rolldown_plugin_lazy_compilation: use loadExports for fetched proxy
to preserve original export names (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9132">#9132</a>)
by <a href="https://github.com/h-a-n-a"><code>@​h-a-n-a</code></a></li>
<li>common: include offending index in HybridIndexVec panic message (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9296">#9296</a>)
by <a href="https://github.com/SAY-5"><code>@​SAY-5</code></a></li>
</ul>
<h3>🚜 Refactor</h3>
<ul>
<li>ecmascript: extract semantic_builder_for_transform helper (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9326">#9326</a>)
by <a href="https://github.com/Dunqing"><code>@​Dunqing</code></a></li>
<li>test: extract reusable static-import-cycle helper (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9332">#9332</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
</ul>
<h3>📚 Documentation</h3>
<ul>
<li>clarify scope of <code>topLevelVar</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9380">#9380</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
<li>meta/design: add ast-mutation design doc (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9338">#9338</a>)
by <a href="https://github.com/hyf0"><code>@​hyf0</code></a></li>
<li>feat: add ai policy in contribution guide (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9315">#9315</a>)
by <a
href="https://github.com/mdong1909"><code>@​mdong1909</code></a></li>
</ul>
<h3>⚡ Performance</h3>
<ul>
<li>binding: enable mimalloc v3 to reduce idle memory (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9349">#9349</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
</ul>
<h3>🧪 Testing</h3>
<ul>
<li>mcs: cover require() in <code>$initial</code> group (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9376">#9376</a>)
by <a href="https://github.com/hyf0"><code>@​hyf0</code></a></li>
<li>add regression for CJS facade chunk merge into entry (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9351">#9351</a>)
by <a
href="https://github.com/IWANABETHATGUY"><code>@​IWANABETHATGUY</code></a></li>
</ul>
<h3>⚙️ Miscellaneous Tasks</h3>
<ul>
<li>switch prepare-release to manual dispatch with version input (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9383">#9383</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>migrate <code>@rolldown/pluginutils</code> to
<code>rolldown/plugins</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9317">#9317</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>deps: pin libmimalloc-sys2 to 0.1.54 (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9372">#9372</a>)
by <a
href="https://github.com/shulaoda"><code>@​shulaoda</code></a></li>
<li>replace <code>igorskyflyer/action-readfile</code> with
<code>cat</code> (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9369">#9369</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>deps: update test262 submodule for tests (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9371">#9371</a>)
by <a
href="https://github.com/rolldown-guard"><code>@​rolldown-guard</code></a>[bot]</li>
<li>use app token for test dep update PRs (<a
href="https://github.com/rolldown/rolldown/tree/HEAD/packages/rolldown/issues/9368">#9368</a>)
by <a
href="https://github.com/sapphi-red"><code>@​sapphi-red</code></a></li>
<li>replace some actions with gh c...

_Description has been truncated_

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Ben Brandt <benjamin.j.brandt@gmail.com>
2026-05-16 22:13:53 +02:00
acp-release-bot[bot]
0db6e3d6f8 chore(main): release 0.34.1 (#668)
🤖 I have created a release *beep* *boop*
---


##
[0.34.1](https://github.com/agentclientprotocol/claude-agent-acp/compare/v0.34.0...v0.34.1)
(2026-05-16)


### Bug Fixes

* load credential error for bedrock gateway
([#667](https://github.com/agentclientprotocol/claude-agent-acp/issues/667))
([8d76be3](8d76be356a))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: acp-release-bot[bot] <246668977+acp-release-bot[bot]@users.noreply.github.com>
2026-05-16 08:13:32 +02:00
Aleksandr Suhinin
8d76be356a fix: load credential error for bedrock gateway (#667)
Sometimes leads to long initialization and error if
AWS_BEARER_TOKEN_BEDROCK:
Could not load credentials from any providers
2026-05-16 08:11:04 +02:00
18 changed files with 1437 additions and 506 deletions

View File

@@ -11,13 +11,6 @@ updates:
interval: "daily"
allow:
- dependency-type: "all"
ignore:
# Pinned to match the peer range of @anthropic-ai/claude-agent-sdk;
# newer minors break type compatibility between the two installed copies.
- dependency-name: "@anthropic-ai/sdk"
update-types:
- "version-update:semver-minor"
- "version-update:semver-major"
groups:
minor:
update-types:

View File

@@ -16,7 +16,7 @@ jobs:
# Generating a GitHub token, so that PRs and tags created by
# the release-please-action can trigger actions workflows.
- name: Generate GitHub token
uses: actions/create-github-app-token@1b10c78c7865c340bc4f6099eb2f838309f1e8c3
uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1
id: generate-token
with:
# GitHub App ID secret name

View File

@@ -1,3 +1,3 @@
{
".": "0.34.0"
".": "0.36.0"
}

View File

@@ -1,5 +1,36 @@
# Changelog
## [0.36.0](https://github.com/agentclientprotocol/claude-agent-acp/compare/v0.35.0...v0.36.0) (2026-05-18)
### Features
* Add experimental session delete support ([#682](https://github.com/agentclientprotocol/claude-agent-acp/issues/682)) ([2162d5a](https://github.com/agentclientprotocol/claude-agent-acp/commit/2162d5af62d493a82381bd88bc8fc67d376e358b))
* Support experimental additionalDirectories field ([#684](https://github.com/agentclientprotocol/claude-agent-acp/issues/684)) ([f37e9a0](https://github.com/agentclientprotocol/claude-agent-acp/commit/f37e9a0d47d8d201d98b2177083664a6781895cc))
## [0.35.0](https://github.com/agentclientprotocol/claude-agent-acp/compare/v0.34.1...v0.35.0) (2026-05-16)
### Features
* **deps:** bump actions/create-github-app-token from 3.1.1 to 3.2.0 ([#669](https://github.com/agentclientprotocol/claude-agent-acp/issues/669)) ([47df1f2](https://github.com/agentclientprotocol/claude-agent-acp/commit/47df1f2a0be57ddb8873ae8e341f748471c7bc53))
* **deps:** bump hono from 4.12.18 to 4.12.19 in the minor group ([#671](https://github.com/agentclientprotocol/claude-agent-acp/issues/671)) ([5d7165d](https://github.com/agentclientprotocol/claude-agent-acp/commit/5d7165d96158da2ddf3087676cdb0a19d1ff57aa))
* **deps:** update to claude-agent-sdk 0.3.143 ([#664](https://github.com/agentclientprotocol/claude-agent-acp/issues/664)) ([27ca2e5](https://github.com/agentclientprotocol/claude-agent-acp/commit/27ca2e5d40917887671cc4c39a854fd8f92c01e6))
* Use SDK settings resolution for defaults ([#677](https://github.com/agentclientprotocol/claude-agent-acp/issues/677)) ([eb1259c](https://github.com/agentclientprotocol/claude-agent-acp/commit/eb1259cf88375ca3c20a219ab99f12f5488fb360))
### Bug Fixes
* Add task hooks for plan state updates ([#676](https://github.com/agentclientprotocol/claude-agent-acp/issues/676)) ([5ff7d50](https://github.com/agentclientprotocol/claude-agent-acp/commit/5ff7d50f0ec7f34a7d9d901223aed73e2dbcce68))
* render local-command-stdout messages instead of dropping them ([#649](https://github.com/agentclientprotocol/claude-agent-acp/issues/649)) ([3b9b7d5](https://github.com/agentclientprotocol/claude-agent-acp/commit/3b9b7d5a56defd925eb2038fa97b6484ad951587))
## [0.34.1](https://github.com/agentclientprotocol/claude-agent-acp/compare/v0.34.0...v0.34.1) (2026-05-16)
### Bug Fixes
* load credential error for bedrock gateway ([#667](https://github.com/agentclientprotocol/claude-agent-acp/issues/667)) ([8d76be3](https://github.com/agentclientprotocol/claude-agent-acp/commit/8d76be356a3e74c58a7c93c3c201cca6a317d784))
## [0.34.0](https://github.com/agentclientprotocol/claude-agent-acp/compare/v0.33.1...v0.34.0) (2026-05-15)

687
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -3,7 +3,7 @@
"publishConfig": {
"access": "public"
},
"version": "0.34.0",
"version": "0.36.0",
"description": "An ACP-compatible coding agent powered by the Claude Agent SDK (TypeScript)",
"main": "dist/lib.js",
"types": "dist/lib.d.ts",
@@ -60,22 +60,22 @@
"author": "Zed Industries",
"license": "Apache-2.0",
"dependencies": {
"@agentclientprotocol/sdk": "0.21.0",
"@anthropic-ai/claude-agent-sdk": "0.2.132",
"@agentclientprotocol/sdk": "0.22.0",
"@anthropic-ai/claude-agent-sdk": "0.3.143",
"zod": "^3.25.0 || ^4.0.0"
},
"devDependencies": {
"@anthropic-ai/sdk": "0.89.0",
"@anthropic-ai/sdk": "0.96.0",
"@eslint/js": "10.0.1",
"@types/node": "25.6.0",
"@typescript-eslint/eslint-plugin": "8.59.2",
"@typescript-eslint/parser": "8.59.2",
"eslint": "10.3.0",
"@types/node": "25.8.0",
"@typescript-eslint/eslint-plugin": "8.59.3",
"@typescript-eslint/parser": "8.59.3",
"eslint": "10.4.0",
"eslint-config-prettier": "10.1.8",
"globals": "17.6.0",
"prettier": "3.8.3",
"ts-node": "10.9.2",
"typescript": "6.0.3",
"vitest": "4.1.5"
"vitest": "4.1.6"
}
}

View File

@@ -17,6 +17,7 @@ import {
ndJsonStream,
NewSessionRequest,
NewSessionResponse,
PermissionOption,
PromptRequest,
PromptResponse,
ReadTextFileRequest,
@@ -36,6 +37,8 @@ import {
SetSessionModeResponse,
CloseSessionRequest,
CloseSessionResponse,
DeleteSessionRequest,
DeleteSessionResponse,
TerminalHandle,
TerminalOutputResponse,
WriteTextFileRequest,
@@ -44,6 +47,7 @@ import {
} from "@agentclientprotocol/sdk";
import {
CanUseTool,
deleteSession,
getSessionMessages,
listSessions,
McpServerConfig,
@@ -69,10 +73,16 @@ import * as path from "node:path";
import packageJson from "../package.json" with { type: "json" };
import { SettingsManager } from "./settings.js";
import {
applyTaskCreate,
applyTaskUpdate,
ClaudePlanEntry,
createPostToolUseHook,
createTaskHook,
parseTaskCreateOutput,
planEntries,
registerHookCallback,
TaskState,
taskStateToPlanEntries,
toolInfoFromToolUse,
toolUpdateFromDiffToolResponse,
toolUpdateFromToolResult,
@@ -152,6 +162,9 @@ type Session = {
* DEFAULT_CONTEXT_WINDOW, refreshed from each result's modelUsage, and
* invalidated when the user switches the session's model. */
contextWindowSize: number;
/** Accumulated task list for the session, keyed by task ID. Task IDs are
* per-session, so this state must not be shared across sessions. */
taskState: TaskState;
};
/** Compute a stable fingerprint of the session-defining params so we can
@@ -615,10 +628,12 @@ export class ClaudeAcpAgent implements Agent {
},
loadSession: true,
sessionCapabilities: {
additionalDirectories: {},
close: {},
delete: {},
fork: {},
list: {},
resume: {},
close: {},
},
},
agentInfo: {
@@ -650,6 +665,7 @@ export class ClaudeAcpAgent implements Agent {
{
cwd: params.cwd,
mcpServers: params.mcpServers ?? [],
additionalDirectories: params.additionalDirectories,
_meta: params._meta,
},
{
@@ -866,6 +882,7 @@ export class ClaudeAcpAgent implements Agent {
case "notification":
case "api_retry":
case "mirror_error":
case "permission_denied":
// Todo: process via status api: https://docs.claude.com/en/docs/claude-code/hooks#hook-output
break;
default:
@@ -1056,6 +1073,7 @@ export class ClaudeAcpAgent implements Agent {
{
clientCapabilities: this.clientCapabilities,
cwd: session.cwd,
taskState: session.taskState,
},
)) {
await this.client.sessionUpdate(notification);
@@ -1104,13 +1122,36 @@ export class ClaudeAcpAgent implements Agent {
}
}
// Slash commands like /compact can generate invalid output... doesn't match
// their own docs: https://docs.anthropic.com/en/docs/claude-code/sdk/sdk-slash-commands#%2Fcompact-compact-conversation-history
// Strip <command-*>/<local-command-stdout> markers and render any
// remaining prose. Skill bodies and built-in slash commands (e.g.
// /usage, /status, /model) arrive wrapped in these tags; pure-marker
// payloads (e.g. /compact's malformed output) strip to null and are
// skipped. Mirrors the replay path at replaySessionHistory.
if (
typeof message.message.content === "string" &&
message.message.content.includes("<local-command-stdout>")
) {
this.logger.log(message.message.content);
const stripped = stripLocalCommandMetadata(message.message.content);
if (typeof stripped === "string") {
for (const notification of toAcpNotifications(
stripped,
message.message.role,
params.sessionId,
this.toolUseCache,
this.client,
this.logger,
{
clientCapabilities: this.clientCapabilities,
parentToolUseId: message.parent_tool_use_id,
cwd: session.cwd,
taskState: session.taskState,
},
)) {
await this.client.sessionUpdate(notification);
}
} else {
this.logger.log(message.message.content);
}
break;
}
@@ -1162,6 +1203,7 @@ export class ClaudeAcpAgent implements Agent {
clientCapabilities: this.clientCapabilities,
parentToolUseId: message.parent_tool_use_id,
cwd: session.cwd,
taskState: session.taskState,
},
)) {
await this.client.sessionUpdate(notification);
@@ -1261,6 +1303,16 @@ export class ClaudeAcpAgent implements Agent {
return {};
}
async unstable_deleteSession(params: DeleteSessionRequest): Promise<DeleteSessionResponse> {
// Tear down any active in-memory state first so the on-disk file isn't
// recreated by an outstanding query writing to it.
if (this.sessions[params.sessionId]) {
await this.teardownSession(params.sessionId);
}
await deleteSession(params.sessionId);
return {};
}
async unstable_setSessionModel(
params: SetSessionModelRequest,
): Promise<SetSessionModelResponse | void> {
@@ -1415,6 +1467,7 @@ export class ClaudeAcpAgent implements Agent {
registerHooks: false,
clientCapabilities: this.clientCapabilities,
cwd: this.sessions[sessionId]?.cwd,
taskState: this.sessions[sessionId]?.taskState,
},
)) {
await this.client.sessionUpdate(notification);
@@ -1445,7 +1498,7 @@ export class ClaudeAcpAgent implements Agent {
}
if (toolName === "ExitPlanMode") {
const optionsAll = [
const optionsAll: PermissionOption[] = [
{ kind: "allow_always", name: 'Yes, and use "auto" mode', optionId: "auto" },
{
kind: "allow_always",
@@ -1724,6 +1777,7 @@ export class ClaudeAcpAgent implements Agent {
sessionId: string;
cwd: string;
mcpServers?: NewSessionRequest["mcpServers"];
additionalDirectories?: NewSessionRequest["additionalDirectories"];
_meta?: NewSessionRequest["_meta"];
}): Promise<NewSessionResponse> {
const existingSession = this.sessions[params.sessionId];
@@ -1748,6 +1802,7 @@ export class ClaudeAcpAgent implements Agent {
{
cwd: params.cwd,
mcpServers: params.mcpServers ?? [],
additionalDirectories: params.additionalDirectories,
_meta: params._meta,
},
{
@@ -1797,7 +1852,7 @@ export class ClaudeAcpAgent implements Agent {
? Object.fromEntries(server.headers.map((e) => [e.name, e.value]))
: undefined,
};
} else {
} else if (!("type" in server)) {
// Stdio type MCP server (with or without explicit type field)
mcpServers[server.name] = {
type: "stdio",
@@ -1861,6 +1916,11 @@ export class ClaudeAcpAgent implements Agent {
const abortController = userProvidedOptions?.abortController || new AbortController();
// Per-session task state. Created here (rather than in the session record
// below) so the TaskCreated/TaskCompleted hook callbacks can close over
// the same Map that the streaming message handler will read from.
const taskState: TaskState = new Map();
const options: Options = {
systemPrompt,
settingSources: ["user", "project", "local"],
@@ -1921,14 +1981,58 @@ export class ClaudeAcpAgent implements Agent {
],
},
],
TaskCreated: [
...(userProvidedOptions?.hooks?.TaskCreated || []),
{
hooks: [
createTaskHook({
taskState,
onChange: async () => {
await this.client.sessionUpdate({
sessionId,
update: {
sessionUpdate: "plan",
entries: taskStateToPlanEntries(taskState),
},
});
},
}),
],
},
],
TaskCompleted: [
...(userProvidedOptions?.hooks?.TaskCompleted || []),
{
hooks: [
createTaskHook({
taskState,
onChange: async () => {
await this.client.sessionUpdate({
sessionId,
update: {
sessionUpdate: "plan",
entries: taskStateToPlanEntries(taskState),
},
});
},
}),
],
},
],
},
...creationOpts,
abortController,
};
// Prefer the official ACP `additionalDirectories` field. Fall back to the
// legacy `_meta.additionalRoots` extension for clients that haven't been
// updated yet. Either source is merged with directories supplied via
// `_meta.claudeCode.options.additionalDirectories` (SDK pass-through).
const acpAdditionalDirectories =
params.additionalDirectories ?? sessionMeta?.additionalRoots ?? [];
options.additionalDirectories = [
...(userProvidedOptions?.additionalDirectories ?? []),
...(sessionMeta?.additionalRoots ?? []),
...acpAdditionalDirectories,
];
if (creationOpts?.resume === undefined || creationOpts?.forkSession) {
@@ -2063,6 +2167,7 @@ export class ClaudeAcpAgent implements Agent {
emitRawSDKMessages: sessionMeta?.claudeCode?.emitRawSDKMessages ?? false,
contextWindowSize:
inferContextWindowFromModel(models.currentModelId) ?? DEFAULT_CONTEXT_WINDOW,
taskState,
};
return {
@@ -2164,7 +2269,7 @@ function createEnvForGateway(request?: GatewayAuthRequest) {
if (request.methodId === "gateway-bedrock") {
return {
CLAUDE_CODE_USE_BEDROCK: "1",
AWS_BEARER_TOKEN_BEDROCK: "",
AWS_BEARER_TOKEN_BEDROCK: " ", // Must be non-empty to bypass pass configuration check
ANTHROPIC_BEDROCK_BASE_URL: request._meta.gateway.baseUrl,
ANTHROPIC_CUSTOM_HEADERS: customHeaders,
};
@@ -2622,8 +2727,10 @@ export function toAcpNotifications(
clientCapabilities?: ClientCapabilities;
parentToolUseId?: string | null;
cwd?: string;
taskState?: TaskState;
},
): SessionNotification[] {
const taskState = options?.taskState ?? new Map();
const registerHooks = options?.registerHooks !== false;
const supportsTerminalOutput = options?.clientCapabilities?._meta?.["terminal_output"] === true;
if (typeof content === "string") {
@@ -2697,6 +2804,15 @@ export function toAcpNotifications(
entries: planEntries(chunk.input as { todos: ClaudePlanEntry[] }),
};
}
} else if (
chunk.name === "TaskCreate" ||
chunk.name === "TaskUpdate" ||
chunk.name === "TaskList" ||
chunk.name === "TaskGet"
) {
// Task* tool_use is suppressed; the plan update is emitted at
// tool_result time once we have the task ID (for TaskCreate) and
// confirmation that the change took effect.
} else {
// Only register hooks on first encounter to avoid double-firing
if (registerHooks && !alreadyCached) {
@@ -2801,7 +2917,36 @@ export function toAcpNotifications(
break;
}
if (toolUse.name !== "TodoWrite") {
if (
toolUse.name === "TaskCreate" ||
toolUse.name === "TaskUpdate" ||
toolUse.name === "TaskList" ||
toolUse.name === "TaskGet"
) {
// Headless/SDK sessions emit Task* tools instead of TodoWrite.
// TaskCreate / TaskUpdate mutate the accumulated task list; TaskList
// and TaskGet are read-only so we just suppress their tool_call /
// tool_result events. The plan update is emitted as a snapshot of
// the accumulated state, mirroring the legacy TodoWrite behavior.
const isError = "is_error" in chunk && chunk.is_error;
if (!isError) {
if (toolUse.name === "TaskCreate") {
applyTaskCreate(
taskState,
toolUse.input as Parameters<typeof applyTaskCreate>[1],
parseTaskCreateOutput(chunk.content),
);
} else if (toolUse.name === "TaskUpdate") {
applyTaskUpdate(taskState, toolUse.input as Parameters<typeof applyTaskUpdate>[1]);
}
}
if (!isError && (toolUse.name === "TaskCreate" || toolUse.name === "TaskUpdate")) {
update = {
sessionUpdate: "plan",
entries: taskStateToPlanEntries(taskState),
};
}
} else if (toolUse.name !== "TodoWrite") {
const { _meta: toolMeta, ...toolUpdate } = toolUpdateFromToolResult(
chunk,
toolUseCache[chunk.tool_use_id],
@@ -2888,6 +3033,7 @@ export function streamEventToAcpNotifications(
options?: {
clientCapabilities?: ClientCapabilities;
cwd?: string;
taskState?: TaskState;
},
): SessionNotification[] {
const event = message.event;
@@ -2904,6 +3050,7 @@ export function streamEventToAcpNotifications(
clientCapabilities: options?.clientCapabilities,
parentToolUseId: message.parent_tool_use_id,
cwd: options?.cwd,
taskState: options?.taskState,
},
);
case "content_block_delta":
@@ -2918,6 +3065,7 @@ export function streamEventToAcpNotifications(
clientCapabilities: options?.clientCapabilities,
parentToolUseId: message.parent_tool_use_id,
cwd: options?.cwd,
taskState: options?.taskState,
},
);
// No content

View File

@@ -1,7 +1,6 @@
#!/usr/bin/env node
// Load managed settings and apply environment variables
import { loadManagedSettings, applyEnvironmentSettings } from "./utils.js";
import { resolveSettings } from "@anthropic-ai/claude-agent-sdk";
import { claudeCliPath, runAcp } from "./acp-agent.js";
if (process.argv.includes("--cli")) {
@@ -35,9 +34,13 @@ if (process.argv.includes("--cli")) {
process.exit(1);
});
} else {
const managedSettings = loadManagedSettings();
if (managedSettings) {
applyEnvironmentSettings(managedSettings);
// Apply env vars from the managed-policy tier before any SDK call so the
// SDK subprocess inherits them. Going through resolveSettings (vs. a raw
// read of managed-settings.json) also picks up MDM sources on macOS and
// HKLM/HKCU on Windows.
const policy = await resolveSettings({ settingSources: [] });
for (const [key, value] of Object.entries(policy.effective.env ?? {})) {
process.env[key] = value;
}
// stdout is used to send messages to the client

View File

@@ -10,25 +10,14 @@ export {
type NewSessionMeta,
type SDKMessageFilter,
} from "./acp-agent.js";
export {
loadManagedSettings,
applyEnvironmentSettings,
nodeToWebReadable,
nodeToWebWritable,
Pushable,
unreachable,
} from "./utils.js";
export { nodeToWebReadable, nodeToWebWritable, Pushable, unreachable } from "./utils.js";
export {
toolInfoFromToolUse,
toDisplayPath,
planEntries,
toolUpdateFromToolResult,
} from "./tools.js";
export {
SettingsManager,
type ClaudeCodeSettings,
type SettingsManagerOptions,
} from "./settings.js";
export { SettingsManager, type SettingsManagerOptions } from "./settings.js";
// Export types
export type { ClaudePlanEntry } from "./tools.js";

View File

@@ -1,5 +1,12 @@
import * as fs from "node:fs";
import * as path from "node:path";
// resolveSettings and filterEscalatingDefaultMode are marked @alpha in the
// SDK; API may shift in a future release.
import {
filterEscalatingDefaultMode,
resolveSettings,
type Settings,
} from "@anthropic-ai/claude-agent-sdk";
import { CLAUDE_CONFIG_DIR } from "./acp-agent.js";
/**
@@ -14,52 +21,10 @@ import { CLAUDE_CONFIG_DIR } from "./acp-agent.js";
* Docs: https://code.claude.com/docs/en/iam#tool-specific-permission-rules
*/
export interface PermissionSettings {
defaultMode?: string;
}
export interface ClaudeCodeSettings {
permissions?: PermissionSettings;
env?: Record<string, string>;
model?: string;
effortLevel?: string;
availableModels?: string[];
}
/**
* Reads and parses a JSON settings file, returning an empty object if not found or invalid.
* Silently ignores missing files (ENOENT) but logs warnings for other errors
* (malformed JSON, permission errors, etc.) to aid debugging.
*/
async function loadSettingsFile(
filePath: string | null,
logger?: { error: (...args: any[]) => void },
): Promise<ClaudeCodeSettings> {
if (!filePath) {
return {};
}
try {
const content = await fs.promises.readFile(filePath, "utf-8");
return JSON.parse(content) as ClaudeCodeSettings;
} catch (error) {
if (error instanceof Error && "code" in error && error.code === "ENOENT") {
return {};
}
logger?.error(`Failed to load settings from ${filePath}:`, error);
return {};
}
}
/**
* Gets the enterprise settings path based on the current platform
*/
export function getManagedSettingsPath(): string {
function getManagedSettingsPath(): string {
switch (process.platform) {
case "darwin":
return "/Library/Application Support/ClaudeCode/managed-settings.json";
case "linux":
return "/etc/claude-code/managed-settings.json";
case "win32":
return "C:\\Program Files\\ClaudeCode\\managed-settings.json";
default:
@@ -73,23 +38,17 @@ export interface SettingsManagerOptions {
}
/**
* Manages Claude Code settings from multiple sources with proper precedence.
* Manages Claude Code settings using the SDK's `resolveSettings` merge engine
* so the values we see match what `query()` would observe.
*
* Settings are loaded from (in order of increasing precedence):
* 1. User settings (~/.claude/settings.json)
* 2. Project settings (<cwd>/.claude/settings.json)
* 3. Local project settings (<cwd>/.claude/settings.local.json)
* 4. Enterprise managed settings (platform-specific path)
*
* The manager watches all settings files for changes and automatically reloads.
* Watches the user/project/local/managed settings files for changes and
* re-resolves through the SDK on update. Escalating `permissions.defaultMode`
* values from repo-committed sources are filtered out via
* `filterEscalatingDefaultMode`, matching the CLI's trust policy.
*/
export class SettingsManager {
private cwd: string;
private userSettings: ClaudeCodeSettings = {};
private projectSettings: ClaudeCodeSettings = {};
private localSettings: ClaudeCodeSettings = {};
private enterpriseSettings: ClaudeCodeSettings = {};
private mergedSettings: ClaudeCodeSettings = {};
private effective: Settings = {};
private watchers: fs.FSWatcher[] = [];
private onChange?: () => void;
private logger: { log: (...args: any[]) => void; error: (...args: any[]) => void };
@@ -127,107 +86,37 @@ export class SettingsManager {
}
/**
* Returns the path to the user settings file
* Paths the SDK reads when resolving settings for this cwd. Watching the
* containing directories means we pick up file creation as well as edits.
*/
private getUserSettingsPath(): string {
return path.join(CLAUDE_CONFIG_DIR, "settings.json");
private getWatchedPaths(): string[] {
return [
path.join(CLAUDE_CONFIG_DIR, "settings.json"),
path.join(this.cwd, ".claude", "settings.json"),
path.join(this.cwd, ".claude", "settings.local.json"),
getManagedSettingsPath(),
];
}
/**
* Returns the path to the project settings file
*/
private getProjectSettingsPath(): string {
return path.join(this.cwd, ".claude", "settings.json");
}
/**
* Returns the path to the local project settings file
*/
private getLocalSettingsPath(): string {
return path.join(this.cwd, ".claude", "settings.local.json");
}
/**
* Loads settings from all sources
* Resolves the effective settings via the SDK and applies the CLI's trust
* filter for escalating `permissions.defaultMode` values.
*/
private async loadAllSettings(): Promise<void> {
const [userSettings, projectSettings, localSettings, enterpriseSettings] = await Promise.all([
loadSettingsFile(this.getUserSettingsPath(), this.logger),
loadSettingsFile(this.getProjectSettingsPath(), this.logger),
loadSettingsFile(this.getLocalSettingsPath(), this.logger),
loadSettingsFile(getManagedSettingsPath(), this.logger),
]);
this.userSettings = userSettings;
this.projectSettings = projectSettings;
this.localSettings = localSettings;
this.enterpriseSettings = enterpriseSettings;
this.mergeSettings();
}
/**
* Merges all settings sources with proper precedence.
* For permissions, rules from all sources are combined.
* Deny rules always take precedence during permission checks.
*/
private mergeSettings(): void {
const allSettings = [
this.userSettings,
this.projectSettings,
this.localSettings,
this.enterpriseSettings,
];
const merged: ClaudeCodeSettings = {};
for (const settings of allSettings) {
if (settings.env) {
merged.env = { ...merged.env, ...settings.env };
}
if (settings.model) {
merged.model = settings.model;
}
if (settings.effortLevel !== undefined) {
merged.effortLevel = settings.effortLevel;
}
if (settings.availableModels !== undefined) {
// Per Claude Code docs: "When `availableModels` is set at multiple
// levels, such as user settings and project settings, arrays are
// merged and deduplicated."
// https://code.claude.com/docs/en/model-config#merge-behavior
const combined = [...(merged.availableModels ?? []), ...settings.availableModels];
merged.availableModels = Array.from(new Set(combined));
}
if (settings.permissions?.defaultMode !== undefined) {
merged.permissions = {
...merged.permissions,
defaultMode: settings.permissions.defaultMode,
};
}
try {
const resolved = await resolveSettings({ cwd: this.cwd });
this.effective = filterEscalatingDefaultMode(resolved);
} catch (error) {
this.logger.error("Failed to resolve settings:", error);
this.effective = {};
}
this.mergedSettings = merged;
}
/**
* Sets up file watchers for all settings files
*/
private setupWatchers(): void {
const paths = [
this.getUserSettingsPath(),
this.getProjectSettingsPath(),
this.getLocalSettingsPath(),
getManagedSettingsPath(),
];
for (const filePath of paths) {
if (!filePath) continue;
for (const filePath of this.getWatchedPaths()) {
try {
const dir = path.dirname(filePath);
const filename = path.basename(filePath);
@@ -278,8 +167,8 @@ export class SettingsManager {
/**
* Returns the current merged settings
*/
getSettings(): ClaudeCodeSettings {
return this.mergedSettings;
getSettings(): Settings {
return this.effective;
}
/**

View File

@@ -126,6 +126,31 @@ describe("ClaudeAcpAgent settings", () => {
expect(response.modes.currentModeId).toBe("acceptEdits");
});
it("drops escalating defaultMode when it comes from project-tier settings", async () => {
// bypassPermissions in .claude/settings.json (a repo-committed tier) is
// filtered by the SDK's trust policy and clamps to 'default'.
const projectDir = path.join(tempDir, "project");
await fs.promises.mkdir(path.join(projectDir, ".claude"), { recursive: true });
await fs.promises.writeFile(
path.join(projectDir, ".claude", "settings.json"),
JSON.stringify({ permissions: { defaultMode: "bypassPermissions" } }),
);
const { getCapturedOptions } = mockQuery();
const { ClaudeAcpAgent } = await import("../acp-agent.js");
const agent: ClaudeAcpAgentType = new ClaudeAcpAgent(createMockClient());
const response = await (agent as any).createSession({
cwd: projectDir,
mcpServers: [],
_meta: { disableBuiltInTools: true },
});
expect(getCapturedOptions().permissionMode).toBe("default");
expect(response.modes.currentModeId).toBe("default");
});
it("defaults to 'default' when no permissions.defaultMode is set", async () => {
const projectDir = path.join(tempDir, "project");
await fs.promises.mkdir(projectDir, { recursive: true });

View File

@@ -1,4 +1,4 @@
import { describe, it, expect, beforeAll, afterAll, vi } from "vitest";
import { describe, it, expect, beforeAll, beforeEach, afterAll, vi } from "vitest";
import { spawn, spawnSync } from "child_process";
import {
Agent,
@@ -35,8 +35,16 @@ import {
type SDKMessageFilter,
} from "../acp-agent.js";
import { Pushable } from "../utils.js";
import { query, SDKAssistantMessage } from "@anthropic-ai/claude-agent-sdk";
import { deleteSession, query, SDKAssistantMessage } from "@anthropic-ai/claude-agent-sdk";
import { randomUUID } from "crypto";
vi.mock("@anthropic-ai/claude-agent-sdk", async (importOriginal) => {
const actual = await importOriginal<typeof import("@anthropic-ai/claude-agent-sdk")>();
return {
...actual,
deleteSession: vi.fn(),
};
});
import type {
BetaToolResultBlockParam,
BetaToolSearchToolResultBlockParam,
@@ -639,6 +647,8 @@ describe("tool conversions", () => {
],
stop_reason: null,
stop_sequence: null,
stop_details: null,
diagnostics: null,
usage: {
input_tokens: 6,
cache_creation_input_tokens: 326,
@@ -1533,6 +1543,7 @@ describe("stop reason propagation", () => {
abortController: new AbortController(),
emitRawSDKMessages: false,
contextWindowSize: 200000,
taskState: new Map(),
};
}
@@ -1676,6 +1687,7 @@ describe("stop reason propagation", () => {
nextPendingOrder: 0,
emitRawSDKMessages: false,
contextWindowSize: 200000,
taskState: new Map(),
};
const response = await agent.prompt({
@@ -1834,6 +1846,7 @@ describe("session/close", () => {
abortController: new AbortController(),
emitRawSDKMessages: false,
contextWindowSize: 200000,
taskState: new Map(),
};
return agent.sessions[sessionId]!;
}
@@ -1883,6 +1896,94 @@ describe("session/close", () => {
});
});
describe("session/delete", () => {
function createMockAgent() {
const mockClient = {
sessionUpdate: async () => {},
} as unknown as AgentSideConnection;
return new ClaudeAcpAgent(mockClient, { log: () => {}, error: () => {} });
}
function injectSession(agent: ClaudeAcpAgent, sessionId: string) {
function* empty() {}
const gen = Object.assign(empty(), { interrupt: vi.fn(), close: vi.fn() });
agent.sessions[sessionId] = {
query: gen as any,
input: new Pushable(),
cancelled: false,
cwd: "/test",
sessionFingerprint: JSON.stringify({ cwd: "/test", mcpServers: [] }),
modes: { currentModeId: "default", availableModes: [] },
models: { currentModelId: "default", availableModels: [] },
modelInfos: [],
settingsManager: { dispose: vi.fn() } as any,
accumulatedUsage: {
inputTokens: 0,
outputTokens: 0,
cachedReadTokens: 0,
cachedWriteTokens: 0,
},
configOptions: [],
promptRunning: false,
pendingMessages: new Map(),
nextPendingOrder: 0,
abortController: new AbortController(),
emitRawSDKMessages: false,
contextWindowSize: 200000,
taskState: new Map(),
};
return agent.sessions[sessionId]!;
}
beforeEach(() => {
vi.mocked(deleteSession).mockReset();
vi.mocked(deleteSession).mockResolvedValue(undefined);
});
it("tears down the active session and deletes it from disk", async () => {
const agent = createMockAgent();
const session = injectSession(agent, "session-1");
const result = await agent.unstable_deleteSession({ sessionId: "session-1" });
expect(result).toEqual({});
expect(agent.sessions["session-1"]).toBeUndefined();
expect(session.query.interrupt).toHaveBeenCalled();
expect(session.settingsManager.dispose).toHaveBeenCalled();
expect(session.abortController.signal.aborted).toBe(true);
expect(deleteSession).toHaveBeenCalledWith("session-1");
});
it("deletes a session from disk that is not currently active", async () => {
const agent = createMockAgent();
const result = await agent.unstable_deleteSession({ sessionId: "not-active" });
expect(result).toEqual({});
expect(deleteSession).toHaveBeenCalledWith("not-active");
});
it("propagates errors from the SDK delete call", async () => {
const agent = createMockAgent();
vi.mocked(deleteSession).mockRejectedValueOnce(new Error("Session not found on disk"));
await expect(agent.unstable_deleteSession({ sessionId: "missing" })).rejects.toThrow(
"Session not found on disk",
);
});
it("does not affect other sessions when deleting one", async () => {
const agent = createMockAgent();
injectSession(agent, "session-a");
injectSession(agent, "session-b");
await agent.unstable_deleteSession({ sessionId: "session-a" });
expect(agent.sessions["session-a"]).toBeUndefined();
expect(agent.sessions["session-b"]).toBeDefined();
});
});
describe("getOrCreateSession param change detection", () => {
function createMockAgent() {
const mockClient = {
@@ -1930,6 +2031,7 @@ describe("getOrCreateSession param change detection", () => {
abortController: new AbortController(),
emitRawSDKMessages: false,
contextWindowSize: 200000,
taskState: new Map(),
};
return agent.sessions[sessionId]!;
}
@@ -2164,6 +2266,7 @@ describe("usage_update computation", () => {
abortController: new AbortController(),
emitRawSDKMessages: false,
contextWindowSize: 200000,
taskState: new Map(),
};
}
@@ -3063,6 +3166,7 @@ describe("emitRawSDKMessages", () => {
abortController: new AbortController(),
emitRawSDKMessages,
contextWindowSize: 200000,
taskState: new Map(),
};
}
@@ -3290,6 +3394,7 @@ describe("result origin handling", () => {
abortController: new AbortController(),
emitRawSDKMessages: false,
contextWindowSize: 200000,
taskState: new Map(),
};
}

View File

@@ -76,4 +76,33 @@ describe("additionalRoots", () => {
});
expect(capturedOptions!.additionalDirectories).toEqual(["/workspace/shared", "", root]);
});
it("prefers the official ACP additionalDirectories field over _meta.additionalRoots", async () => {
await agent.newSession({
cwd: "/test",
mcpServers: [],
additionalDirectories: ["/from/official"],
_meta: { additionalRoots: ["/from/meta"] },
});
expect(capturedOptions!.additionalDirectories).toEqual(["/from/official"]);
});
it("merges official ACP additionalDirectories with claudeCode SDK additionalDirectories", async () => {
await agent.newSession({
cwd: "/test",
mcpServers: [],
additionalDirectories: ["/from/official"],
_meta: { claudeCode: { options: { additionalDirectories: ["/from/sdk"] } } },
});
expect(capturedOptions!.additionalDirectories).toEqual(["/from/sdk", "/from/official"]);
});
it("falls back to _meta.additionalRoots when the official field is omitted", async () => {
await agent.newSession({
cwd: "/test",
mcpServers: [],
_meta: { additionalRoots: ["/from/meta"] },
});
expect(capturedOptions!.additionalDirectories).toEqual(["/from/meta"]);
});
});

View File

@@ -154,7 +154,7 @@ describe("authorization", () => {
options: expect.objectContaining({
env: expect.objectContaining({
CLAUDE_CODE_USE_BEDROCK: "1",
AWS_BEARER_TOKEN_BEDROCK: "",
AWS_BEARER_TOKEN_BEDROCK: " ",
ANTHROPIC_BEDROCK_BASE_URL: "https://gateway.example",
ANTHROPIC_CUSTOM_HEADERS: "custom-header: test",
}),

View File

@@ -141,4 +141,66 @@ describe("SettingsManager", () => {
expect(settings.permissions?.defaultMode).toBe("plan");
});
});
describe("escalating defaultMode trust filter", () => {
// The SDK's filterEscalatingDefaultMode drops escalating values
// (bypassPermissions / auto / acceptEdits) that came from a repo-committed
// tier (.claude/settings.json), preventing a checked-in file from
// silently escalating permissions. Local (.claude/settings.local.json)
// and user-tier sources are not committed by convention, so escalating
// values from those tiers are preserved.
it.each(["bypassPermissions", "auto", "acceptEdits"] as const)(
"drops %s when set in project-tier settings",
async (mode) => {
const claudeDir = path.join(tempDir, ".claude");
await fs.promises.mkdir(claudeDir, { recursive: true });
await fs.promises.writeFile(
path.join(claudeDir, "settings.json"),
JSON.stringify({ permissions: { defaultMode: mode } }),
);
settingsManager = new SettingsManager(tempDir);
await settingsManager.initialize();
expect(settingsManager.getSettings().permissions?.defaultMode).toBeUndefined();
},
);
it.each(["plan", "dontAsk"] as const)(
"preserves non-escalating %s from project-tier settings",
async (mode) => {
const claudeDir = path.join(tempDir, ".claude");
await fs.promises.mkdir(claudeDir, { recursive: true });
await fs.promises.writeFile(
path.join(claudeDir, "settings.json"),
JSON.stringify({ permissions: { defaultMode: mode } }),
);
settingsManager = new SettingsManager(tempDir);
await settingsManager.initialize();
expect(settingsManager.getSettings().permissions?.defaultMode).toBe(mode);
},
);
it("preserves escalating defaultMode when it comes from local-tier settings", async () => {
// settings.local.json is git-ignored by convention, so the trust
// filter does not apply.
const claudeDir = path.join(tempDir, ".claude");
await fs.promises.mkdir(claudeDir, { recursive: true });
await fs.promises.writeFile(
path.join(claudeDir, "settings.local.json"),
JSON.stringify({ permissions: { defaultMode: "acceptEdits" } }),
);
settingsManager = new SettingsManager(tempDir);
await settingsManager.initialize();
expect(settingsManager.getSettings().permissions?.defaultMode).toBe("acceptEdits");
});
});
});

View File

@@ -14,8 +14,14 @@ import { toAcpNotifications, ToolUseCache, Logger } from "../acp-agent.js";
import {
toolUpdateFromToolResult,
createPostToolUseHook,
createTaskHook,
toolInfoFromToolUse,
planEntries,
applyTaskCreate,
applyTaskUpdate,
parseTaskCreateOutput,
taskStateToPlanEntries,
TaskState,
} from "../tools.js";
describe("rawOutput in tool call updates", () => {
@@ -1541,3 +1547,404 @@ describe("toAcpNotifications - TodoWrite with undefined input regression", () =>
expect(planUpdates).toHaveLength(1);
});
});
describe("parseTaskCreateOutput", () => {
it("parses JSON-string content", () => {
const parsed = parseTaskCreateOutput(JSON.stringify({ task: { id: "1", subject: "X" } }));
expect(parsed).toEqual({ task: { id: "1", subject: "X" } });
});
it("parses array-of-text-block content", () => {
const parsed = parseTaskCreateOutput([
{ type: "text", text: JSON.stringify({ task: { id: "2", subject: "Y" } }) },
]);
expect(parsed).toEqual({ task: { id: "2", subject: "Y" } });
});
it("returns undefined for non-JSON content", () => {
expect(parseTaskCreateOutput("not json")).toBeUndefined();
expect(parseTaskCreateOutput([{ type: "text", text: "not json" }])).toBeUndefined();
});
it("returns undefined when task.id is missing", () => {
expect(parseTaskCreateOutput(JSON.stringify({ task: { subject: "X" } }))).toBeUndefined();
});
});
describe("applyTaskCreate / applyTaskUpdate", () => {
it("creates an entry on TaskCreate when both input and output are present", () => {
const state: TaskState = new Map();
applyTaskCreate(
state,
{ subject: "Write tests", description: "Cover Task* flow", activeForm: "Writing tests" },
{ task: { id: "1", subject: "Write tests" } },
);
expect(state.get("1")).toEqual({
subject: "Write tests",
status: "pending",
activeForm: "Writing tests",
description: "Cover Task* flow",
});
});
it("is a no-op when the output has no task ID", () => {
const state: TaskState = new Map();
applyTaskCreate(state, { subject: "X", description: "Y" }, undefined);
expect(state.size).toBe(0);
});
it("updates fields by task ID and keeps insertion order in plan entries", () => {
const state: TaskState = new Map();
applyTaskCreate(state, { subject: "A", description: "" }, { task: { id: "1", subject: "A" } });
applyTaskCreate(state, { subject: "B", description: "" }, { task: { id: "2", subject: "B" } });
applyTaskUpdate(state, { taskId: "1", status: "in_progress" });
expect(taskStateToPlanEntries(state)).toEqual([
{ content: "A", status: "in_progress", priority: "medium" },
{ content: "B", status: "pending", priority: "medium" },
]);
});
it("removes entries when status is 'deleted'", () => {
const state: TaskState = new Map();
applyTaskCreate(state, { subject: "A", description: "" }, { task: { id: "1", subject: "A" } });
applyTaskUpdate(state, { taskId: "1", status: "deleted" });
expect(state.size).toBe(0);
});
it("creates a placeholder entry when TaskUpdate carries a subject for an unseen task", () => {
const state: TaskState = new Map();
applyTaskUpdate(state, { taskId: "5", subject: "Late arrival", status: "in_progress" });
expect(state.get("5")).toEqual({
subject: "Late arrival",
status: "in_progress",
activeForm: undefined,
description: undefined,
});
});
it("skips TaskUpdate for an unseen task when no subject is available", () => {
const state: TaskState = new Map();
applyTaskUpdate(state, { taskId: "5", status: "in_progress" });
// Without a subject we'd render an empty-content plan entry, so the
// update is dropped instead of synthesizing a blank placeholder.
expect(state.has("5")).toBe(false);
});
});
describe("toAcpNotifications - Task* tools", () => {
const mockClient = {} as AgentSideConnection;
const mockLogger: Logger = { log: () => {}, error: () => {} };
it("suppresses tool_call for TaskCreate/TaskUpdate/TaskList/TaskGet on tool_use", () => {
const toolUseCache: ToolUseCache = {};
const taskState: TaskState = new Map();
const notifications = toAcpNotifications(
[
{ type: "tool_use", id: "1", name: "TaskCreate", input: { subject: "A", description: "" } },
{
type: "tool_use",
id: "2",
name: "TaskUpdate",
input: { taskId: "1", status: "in_progress" },
},
{ type: "tool_use", id: "3", name: "TaskList", input: {} },
{ type: "tool_use", id: "4", name: "TaskGet", input: { taskId: "1" } },
] as any,
"assistant",
"test-session",
toolUseCache,
mockClient,
mockLogger,
{ taskState },
);
expect(notifications).toHaveLength(0);
expect(taskState.size).toBe(0);
});
it("emits a plan snapshot after a TaskCreate tool_result and accumulates state", () => {
const toolUseCache: ToolUseCache = {};
const taskState: TaskState = new Map();
toAcpNotifications(
[
{
type: "tool_use",
id: "1",
name: "TaskCreate",
input: { subject: "First", description: "" },
},
] as any,
"assistant",
"test-session",
toolUseCache,
mockClient,
mockLogger,
{ taskState },
);
const created = toAcpNotifications(
[
{
type: "tool_result",
tool_use_id: "1",
content: JSON.stringify({ task: { id: "1", subject: "First" } }),
is_error: false,
},
] as any,
"user",
"test-session",
toolUseCache,
mockClient,
mockLogger,
{ taskState },
);
expect(created).toHaveLength(1);
expect(created[0].update).toMatchObject({
sessionUpdate: "plan",
entries: [{ content: "First", status: "pending", priority: "medium" }],
});
// A second TaskCreate accumulates rather than replacing.
toAcpNotifications(
[
{
type: "tool_use",
id: "2",
name: "TaskCreate",
input: { subject: "Second", description: "" },
},
] as any,
"assistant",
"test-session",
toolUseCache,
mockClient,
mockLogger,
{ taskState },
);
const second = toAcpNotifications(
[
{
type: "tool_result",
tool_use_id: "2",
content: JSON.stringify({ task: { id: "2", subject: "Second" } }),
is_error: false,
},
] as any,
"user",
"test-session",
toolUseCache,
mockClient,
mockLogger,
{ taskState },
);
expect(second[0].update).toMatchObject({
sessionUpdate: "plan",
entries: [
{ content: "First", status: "pending", priority: "medium" },
{ content: "Second", status: "pending", priority: "medium" },
],
});
});
it("emits a plan snapshot reflecting status changes after a TaskUpdate tool_result", () => {
const toolUseCache: ToolUseCache = {};
const taskState: TaskState = new Map([["1", { subject: "First", status: "pending" as const }]]);
toolUseCache["update-1"] = {
type: "tool_use",
id: "update-1",
name: "TaskUpdate",
input: { taskId: "1", status: "completed" },
};
const notifications = toAcpNotifications(
[
{
type: "tool_result",
tool_use_id: "update-1",
content: JSON.stringify({
success: true,
taskId: "1",
updatedFields: ["status"],
}),
is_error: false,
},
] as any,
"user",
"test-session",
toolUseCache,
mockClient,
mockLogger,
{ taskState },
);
expect(notifications).toHaveLength(1);
expect(notifications[0].update).toMatchObject({
sessionUpdate: "plan",
entries: [{ content: "First", status: "completed", priority: "medium" }],
});
});
it("suppresses TaskList and TaskGet tool_result without touching task state", () => {
const toolUseCache: ToolUseCache = {
"list-1": { type: "tool_use", id: "list-1", name: "TaskList", input: {} },
"get-1": { type: "tool_use", id: "get-1", name: "TaskGet", input: { taskId: "1" } },
};
const taskState: TaskState = new Map([
["1", { subject: "Existing", status: "in_progress" as const }],
]);
const notifications = toAcpNotifications(
[
{ type: "tool_result", tool_use_id: "list-1", content: "...", is_error: false },
{ type: "tool_result", tool_use_id: "get-1", content: "...", is_error: false },
] as any,
"user",
"test-session",
toolUseCache,
mockClient,
mockLogger,
{ taskState },
);
expect(notifications).toHaveLength(0);
expect(taskState.get("1")).toEqual({ subject: "Existing", status: "in_progress" });
});
it("does not apply TaskCreate/TaskUpdate when the tool_result reports an error", () => {
const toolUseCache: ToolUseCache = {
"create-1": {
type: "tool_use",
id: "create-1",
name: "TaskCreate",
input: { subject: "A", description: "" },
},
};
const taskState: TaskState = new Map();
const notifications = toAcpNotifications(
[
{
type: "tool_result",
tool_use_id: "create-1",
content: "task creation failed",
is_error: true,
},
] as any,
"user",
"test-session",
toolUseCache,
mockClient,
mockLogger,
{ taskState },
);
expect(notifications).toHaveLength(0);
expect(taskState.size).toBe(0);
});
});
describe("createTaskHook", () => {
it("registers a task on TaskCreated and fires onChange", async () => {
const taskState: TaskState = new Map();
let changes = 0;
const hook = createTaskHook({
taskState,
onChange: async () => {
changes++;
},
});
await hook(
{
hook_event_name: "TaskCreated",
task_id: "t-1",
task_subject: "Investigate flaky test",
task_description: "Repro and fix",
} as any,
undefined,
{ signal: new AbortController().signal },
);
expect(taskState.get("t-1")).toEqual({
subject: "Investigate flaky test",
status: "pending",
description: "Repro and fix",
});
expect(changes).toBe(1);
});
it("does not clobber an existing entry on TaskCreated", async () => {
const taskState: TaskState = new Map([
["t-1", { subject: "Investigate flaky test", status: "in_progress" as const }],
]);
let changes = 0;
const hook = createTaskHook({
taskState,
onChange: async () => {
changes++;
},
});
await hook(
{
hook_event_name: "TaskCreated",
task_id: "t-1",
task_subject: "Investigate flaky test",
} as any,
undefined,
{ signal: new AbortController().signal },
);
expect(taskState.get("t-1")?.status).toBe("in_progress");
expect(changes).toBe(0);
});
it("marks a task completed on TaskCompleted", async () => {
const taskState: TaskState = new Map([
["t-1", { subject: "Investigate flaky test", status: "in_progress" as const }],
]);
let changes = 0;
const hook = createTaskHook({
taskState,
onChange: async () => {
changes++;
},
});
await hook(
{
hook_event_name: "TaskCompleted",
task_id: "t-1",
task_subject: "Investigate flaky test",
} as any,
undefined,
{ signal: new AbortController().signal },
);
expect(taskState.get("t-1")?.status).toBe("completed");
expect(changes).toBe(1);
});
it("is a no-op for unrelated hook events", async () => {
const taskState: TaskState = new Map();
let changes = 0;
const hook = createTaskHook({
taskState,
onChange: async () => {
changes++;
},
});
await hook({ hook_event_name: "PostToolUse", tool_name: "Read" } as any, undefined, {
signal: new AbortController().signal,
});
expect(taskState.size).toBe(0);
expect(changes).toBe(0);
});
});

View File

@@ -14,6 +14,9 @@ import {
FileWriteInput,
GlobInput,
GrepInput,
TaskCreateInput,
TaskCreateOutput,
TaskUpdateInput,
TodoWriteInput,
WebFetchInput,
WebSearchInput,
@@ -367,6 +370,40 @@ export function toolInfoFromToolUse(
};
}
case "TaskCreate": {
const input = toolUse.input as TaskCreateInput | undefined;
return {
title: input?.subject ? `Create task: ${input.subject}` : "Create task",
kind: "think",
content: [],
};
}
case "TaskUpdate": {
const input = toolUse.input as TaskUpdateInput | undefined;
return {
title: input?.subject ? `Update task: ${input.subject}` : "Update task",
kind: "think",
content: [],
};
}
case "TaskList": {
return {
title: "List tasks",
kind: "think",
content: [],
};
}
case "TaskGet": {
return {
title: "Get task",
kind: "think",
content: [],
};
}
case "ExitPlanMode": {
const planInput = toolUse.input as { plan?: string } | undefined;
return {
@@ -669,6 +706,103 @@ export function planEntries(input: { todos: ClaudePlanEntry[] } | undefined): Pl
}));
}
/**
* Per-session task list accumulated from Task* tool calls (TaskCreate /
* TaskUpdate). The headless/SDK session emits these as incremental tool
* calls keyed by task ID, replacing the snapshot-style TodoWrite tool.
* Iteration order is insertion order (Map semantics), matching the order
* tasks are created.
*/
export type TaskEntry = {
subject: string;
status: "pending" | "in_progress" | "completed";
activeForm?: string;
description?: string;
};
export type TaskState = Map<string, TaskEntry>;
/**
* Best-effort parse of a TaskCreate tool_result content into the structured
* TaskCreateOutput. The SDK delivers tool outputs either as a string or as
* an array of TextBlockParam-like blocks containing JSON text; try both.
*/
export function parseTaskCreateOutput(content: unknown): TaskCreateOutput | undefined {
const tryParse = (text: string): TaskCreateOutput | undefined => {
try {
const parsed = JSON.parse(text);
if (
parsed &&
typeof parsed === "object" &&
parsed.task &&
typeof parsed.task.id === "string"
) {
return parsed as TaskCreateOutput;
}
} catch {
// ignore
}
return undefined;
};
if (typeof content === "string") {
return tryParse(content);
}
if (Array.isArray(content)) {
for (const block of content) {
if (block && typeof block === "object" && "type" in block && block.type === "text") {
const text = (block as { text?: unknown }).text;
if (typeof text === "string") {
const parsed = tryParse(text);
if (parsed) return parsed;
}
}
}
}
return undefined;
}
export function applyTaskCreate(
state: TaskState,
input: TaskCreateInput | undefined,
output: TaskCreateOutput | undefined,
): void {
const taskId = output?.task?.id;
if (!taskId || !input) return;
state.set(taskId, {
subject: input.subject,
status: "pending",
activeForm: input.activeForm,
description: input.description,
});
}
export function applyTaskUpdate(state: TaskState, input: TaskUpdateInput | undefined): void {
if (!input?.taskId) return;
if (input.status === "deleted") {
state.delete(input.taskId);
return;
}
const existing = state.get(input.taskId);
// Without a subject from either the existing entry or the update payload,
// we'd produce a plan entry with empty `content` — drop the update.
const subject = input.subject ?? existing?.subject;
if (!subject) return;
state.set(input.taskId, {
subject,
status: input.status ?? existing?.status ?? "pending",
activeForm: input.activeForm ?? existing?.activeForm,
description: input.description ?? existing?.description,
});
}
export function taskStateToPlanEntries(state: TaskState): PlanEntry[] {
return Array.from(state.values()).map((task) => ({
content: task.subject,
status: task.status,
priority: "medium",
}));
}
export function markdownEscape(text: string): string {
let escape = "```";
for (const [m] of text.matchAll(/^```+/gm)) {
@@ -797,3 +931,38 @@ export const createPostToolUseHook =
}
return { continue: true };
};
/**
* Hook callback for `TaskCreated` / `TaskCompleted` events. The SDK fires
* these for both user-facing TaskCreate tool calls and subagent task
* creation, giving us `task_id` + `task_subject` without having to parse
* tool_result payloads.
*
* Populating `taskState` from the hook means a later `TaskUpdate` (which
* typically only carries `taskId` + `status`) finds an existing entry with
* a real subject, instead of synthesizing a placeholder with empty content.
*/
export const createTaskHook =
(options: { taskState: TaskState; onChange?: () => Promise<void> }): HookCallback =>
async (input): Promise<{ continue: boolean }> => {
const taskId =
"task_id" in input && typeof input.task_id === "string" ? input.task_id : undefined;
if (!taskId) return { continue: true };
if (input.hook_event_name === "TaskCreated") {
if (!input.task_subject) return { continue: true };
if (options.taskState.has(taskId)) return { continue: true };
options.taskState.set(taskId, {
subject: input.task_subject,
status: "pending",
description: input.task_description,
});
if (options.onChange) await options.onChange();
} else if (input.hook_event_name === "TaskCompleted") {
const existing = options.taskState.get(taskId);
if (!existing || existing.status === "completed") return { continue: true };
options.taskState.set(taskId, { ...existing, status: "completed" });
if (options.onChange) await options.onChange();
}
return { continue: true };
};

View File

@@ -2,9 +2,7 @@
import { Readable, Writable } from "node:stream";
import { WritableStream, ReadableStream } from "node:stream/web";
import { readFileSync } from "node:fs";
import { Logger } from "./acp-agent.js";
import { ClaudeCodeSettings, getManagedSettingsPath } from "./settings.js";
// Useful for bridging push-based and async-iterator-based code.
export class Pushable<T> implements AsyncIterable<T> {
@@ -89,19 +87,3 @@ export function unreachable(value: never, logger: Logger = console) {
export function sleep(time: number): Promise<void> {
return new Promise((resolve) => setTimeout(resolve, time));
}
export function loadManagedSettings(): ClaudeCodeSettings | null {
try {
return JSON.parse(readFileSync(getManagedSettingsPath(), "utf8")) as ClaudeCodeSettings;
} catch {
return null;
}
}
export function applyEnvironmentSettings(settings: ClaudeCodeSettings): void {
if (settings.env) {
for (const [key, value] of Object.entries(settings.env)) {
process.env[key] = value;
}
}
}