fix: stop named-importing CallId/ToolCallId from dsh-llm - #17
Closed
yyh-001 wants to merge 1 commit into
Closed
Conversation
rc and alpha.1 export different brand constructors. A missing named ESM import crashes plugin-tree load. Brand tool-call ids through StreamChunk instead. Co-authored-by: Cursor <cursoragent@cursor.com>
Author
|
Closing this PR. The supported path is now dsh 0.1.2-alpha.2+ with |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Desktop / dsh
0.1.2-alpha.1fails to load@mars-sea/dsh-commandcode-provider@latest(0.9.1) with:@deepseek-ai/dsh-llmrenamed the brandedCallIdconstructor toToolCallIdin0.1.2-alpha.1. A named ESM import of the missing name fails at instantiation and the whole plugin tree dies (deepseek-ai/deepseek-harness#4827).A previous attempt (#9) switched the named import to
ToolCallId, which would then break rc hosts that still exportCallId. Copilot's review asked for a namespace fallback instead of a hard named import.This PR brands tool-call ids through the host
StreamChunkvocabulary (Extract<StreamChunk, { type: 'tool-call-delta' }>['id']) and does not import either constructor name. Same pattern asai/adapt-dsh-0.1.2.Changes
src/adapter.ts— localtoolCallId()helper; dropToolCallIdfrom the@deepseek-ai/dsh-llmvalue importtests/adapter.test.ts— regression that the adapter must not named-importCallIdorToolCallIdCHANGELOG.md— Unreleased noteTest plan
node --import tsx --test tests/adapter.test.ts(71 pass)tool-call/tool-call-deltaids still round-tripNote for 0.9.x /
@latestCurrent
mainis the0.10.0-alphaline (@alpha, dsh ≥ 0.1.2-alpha.2). Desktop users on0.1.2-alpha.1still install@latest0.9.1, which is the line that stillimport { CallId }.The same adapter change is on
yyh-001:fix/0.9.2-callid-compat(based onv0.9.1, version bumped to 0.9.2, peers include0.1.2-alpha.1). Please cut a0.9.xbranch fromv0.9.1and publish 0.9.2 to thelatesttag so Desktop alpha.1 users stop hitting this on install. That branch should not be merged intomain.