This is the sibling of zen-free 0.1.4 (6a5dd01). magpie's gateway goes on
with an Anthropic or Responses reply that was cut short, but not with a
Chat Completions one. For those, the error frame after a 200 threw away
the reply the client had already been shown.
Now, when a chat stream loses Zed's stream_ended, the plugin looks at what
the choices already said:
- If no choice is still open, only [DONE] is added.
- If a choice said text or reasoning and has no tool call half written,
each open choice gets the note and a `stop`, then [DONE].
- If nothing was said, or a tool call is still unfinished, it fails as
before.
Anthropic, Responses and non-streamed replies are unchanged.
Run: HOME=$(mktemp -d) bun test packages/zed gave 31 pass. The whole
repo's bun test gave 1129 pass, 0 fail. bun scripts/check.mjs passed. On
the old index.mjs, the 2 new tests that cover the cut-short endings fail.
With the tool-call guard removed by hand, the tool-call test fails.
Not tried: a real Zed account (there is none to test with). The
upstream's cut can't be triggered.
12 lines
478 B
JSON
12 lines
478 B
JSON
{
|
|
"name": "@magpie-community/opencode-zed-auth",
|
|
"version": "0.1.7",
|
|
"description": "Sign in to a Zed subscription (Zed Pro, trial, student, business) from OpenCode or magpie",
|
|
"type": "module",
|
|
"main": "./index.mjs",
|
|
"files": ["index.mjs", "README.md"],
|
|
"keywords": ["opencode", "opencode-plugin", "magpie", "zed"],
|
|
"license": "MIT",
|
|
"repository": { "type": "git", "url": "git+https://github.com/magpie-community/plugins.git", "directory": "packages/zed" }
|
|
}
|