chore: ACP SDK rejects usage_update notifications from claude-agent-acp
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 68/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- typescript
- Domain
- backend, testing-qa
Research direction
Start in apps/workers/coder-acp-claude-code and inspect the dependency declaration and notification handling, then read claude-code.integration.test.ts to reproduce the logged validation error. Done means usage_update notifications no longer produce non-fatal Error handling notification messages and the integration test still passes.
Written by the indexing model from the issue text.
Description
Original author: @cedricvidal
Summary
The Claude Code ACP worker (and its integration test) logs noisy Error handling notification messages for usage_update session notifications. The test still passes — these are non-fatal — but the errors clutter logs and may mask real issues.
Error
Error handling notification {
jsonrpc: '2.0',
method: 'session/update',
params: {
sessionId: '...',
update: { sessionUpdate: 'usage_update', used: 16690, size: 200000 }
}
} {
code: -32602,
message: 'Invalid params',
data: {
_errors: [
'Invalid input: expected object, received undefined',
...
]
}
}
Root Cause
The usage_update notification is a newer ACP protocol feature sent by claude-agent-acp@0.29.1. The pinned @agentclientprotocol/sdk@0.13.1 doesn't have a schema for this notification type, so its JSON-RPC validation layer rejects the shape before it reaches the sessionUpdate handler's default: break; case.
Affected Components
apps/workers/coder-acp-claude-code(production worker)- Integration test (
claude-code.integration.test.ts)
Fix Options
- Bump
@agentclientprotocol/sdkto a version that includes theusage_updateschema (preferred) - Suppress the error by adding a try/catch or custom notification handler at the SDK level (workaround)
Environment
@agentclientprotocol/claude-agent-acp:0.29.1@agentclientprotocol/sdk:0.13.1
- Dominant language
- TypeScript
- Stars
- 4
- Forks
- 1
- Avg merge
- 5d 7h
- Merged PRs (30d)
- 10
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/scope
-
author: github-actions[bot] worker-update
Difficulty 1/5 1-3 hours Newbie friendliness 85/100
-
author: github-actions[bot] worker-update
Difficulty 1/5 Under an hour Newbie friendliness 88/100
-
author: github-actions[bot] worker-update
Difficulty 1/5 1-3 hours Newbie friendliness 78/100
-
author: JaGord documentation good first issue UI
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
author: cedricvidal bug portal
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Similar issues
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 91/100
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Difficulty 1/5 Under an hour Newbie friendliness 95/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Automattic/studio#4908 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100