You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Independent reproduction, and a suggestion on the declaration style.
Reproduction
Hit the same bug from a different angle before finding this PR: DSH 0.1.0-rc.7 (host packages resolving at rc.8), pnpm 11, Windows, on a dsh-tui profile rather than Web. Same failure, same mechanism, and it reproduced under both the stock standard preset and a custom one, so it is not preset-specific.
What isolated it here was an asymmetry between two profiles on the same machine:
profile
local @deepseek-ai/dsh-tools
tool calls
web
absent (this profile happened to resolve without it)
work
dsh-tui
present, shadows the flat fallback
fail, every call
Both profiles ran byte-identical dsh-tools, with scheduler.prepare on the same line. Only the presence of the duplicate tracked the failure, which is what ruled out version drift. Removing the profile-local copy by hand fixed it immediately. So: confirming your diagnosis from a second environment.
Suggestion: peerDependencies rather than devDependencies
Both stop the duplicate from being installed, so this is not a correctness argument. The reason to prefer peers here is that it costs nothing extra in a DSH profile: DSH writes the setting into every profile template itself, so peers are never auto-installed.
With that guaranteed, peerDependencies has the same install behaviour as devDependencies and additionally declares which host version the plugin expects, which devDependencies communicates to consumers not at all.
That contract is worth something concretely. The other two commits in #4 fix a silent rc.6 → rc.7 client-face breakage in this plugin: dsh.client.inject named @deepseek-ai/dsh-client-ui-slots, which rc.7 removed. An unresolvable module name stops the client bundle from being served, so the host rows still reported Mounted, Enabled, the settings panel never rendered, and nothing was logged to the console. A declared peer range would have surfaced that at install time instead. For reference, @deepseek-harness-tui/dsh-tui declares its 24 host packages as peers for the same reason, and prints an explicit drift warning per package when the resolved version differs from the validated one.
If that seems reasonable it is a small edit on top of this PR, and your regression test could assert the peer block is present in addition to asserting the packages stay out of dependencies. Happy either way, this PR came first and fixes the bug.
I have the same manifest change sitting on my branch in #4 purely because my own install depends on it; it should be dropped in favour of whatever lands here.
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
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.
修改内容
dependencies移到devDependencies@deepseek-ai/schemastery作为运行时依赖dependencies问题原因
安装插件后会额外安装一份 DSH 宿主运行时包,包括
@deepseek-ai/dsh-tools。由于
TOOL_RUNTIME_SCHEDULER使用模块实例相关的Symbol(),宿主与插件加载不同物理路径下的dsh-tools后,两边的 Symbol 身份不同,最终导致工具执行阶段无法获取调度器,并出现:本次修改通过避免插件安装独立的 DSH 宿主运行时副本来解决该问题。
验证
npm test:通过npm pack --dry-run:通过Fixes #2