Replies: 3 comments
|
Great report — the root cause is correct and the E2E evidence (both Windows and Linux, same package md5, controls A/B) is solid. I dug into the source and found an important nuance about the fix that I think changes the shape of it. The reporter's "one line: add
// schema.ts ~line 342 (author-time validation)
if (Object.hasOwn(input, 'type')) authorError(`${path} cannot declare both type and oneOf`)So adding The runtime error you hit ( Because
My read: option 1 (reshaping the param to avoid top-level One further note: |
|
E2E validation — extended test matrix (2026-09-04, JKDTPC Windows, DSH 0.1.1-rc.2, Node v24.13.0) After the initial 3-plugin E2E (§ Evidence 5 in the main report), a final consolidated run extended the matrix: Accepted (plugin arrives as OBJECT, validation intact): Rejected as expected ( Rollback leg: backup ( Negative result: NONE — patch active and functional. |
|
Re: maintainer feedback — local adoption + incident note (fixed form verified) Thank you — the author-time
Original report content stands (root cause: typeless |
Uh oh!
There was an error while loading. Please reload this page.
[bug] cordis_define: typeless
pluginparameter schema makes the web client stringify the object argumentMerged draft — evidence consolidated by AICORE (Linux) + JKDTPC (Windows), 2026-09-03. E2E validation completed 2026-09-04 (§ Evidence 5-7).
Environment
@deepseek-ai/dsh0.1.1-rc.2 (npm install), observed on Windows 11 (dsh web process,dsh web --patch …, GUI on :3080), Node v24.13.0 (npm-installed CLI); package contents cross-checked on Linux (AICORE) — identicaldsh-tool-cordisfile on both machinesnode_modules/@deepseek-ai/dsh-tool-cordis/lib/index.js, md5cf9d4cf4096378c1c14e6aa5343247d9(unpatched, identical on both machines)Symptom
Calling the
cordis_definetool from a session in the dsh web process (web GUI :3080) with a fully-formed argument object fails:args.pluginarrives at the host as a string (the JSON object serialized), so neitheroneOfbranch (both declaretype: "object") matches. Expected:pluginarrives as an object and the define succeeds.Observed 2026-08-31, documented baseline:
messaging-wake-bridge-SETUP.md(JKDTPC machine).Root cause
The tool's parameter schema declares the parameter without a top-level type:
(
dsh-tool-cordis/lib/index.js,cordis_definetool definition, ~line 7189.)Because the parameter carries no
type, the web client's tool-call serialization stringifies the argument before it reaches the host. The host-side validator then — correctly — rejects the string against the object-onlyoneOfbranches (validator:@deepseek-ai/dsh-tools/lib/index.jsline 417,must match exactly one oneOf branch (matched ${frame.matches})). The validator behaves as designed; the typeless schema is the trigger.Evidence
args.plugin= string. NeitheroneOfbranch matched.cordis.ymlcomposition rows load normally in the same process — the defect is isolated to the dynamic tool-call path, not a wholesale schema-file breakage.cordis_definefrom a non-web session succeeds with an objectpluginargument (probe plugin defined and then removed). The defect does not manifest on the session/loopback path — it is specific to the web client's argument serialization.node --checkpasses. E2E validation followed (next items).dsh webrestart, Windows):cordis_definecalled via the runtime API in the web process withpluginas a well-formed object — define succeeded (3 test plugins defined; acceptance criteria met:pluginarrives as an object, arity preserved, string arguments to other parameters not regressed). Patched schema validation still correctly rejects invalididPrefixvalues (non-letter characters, >6 characters) — the added line did not weaken validation.npmupdate had silently overwrittennode_modulesand removed the patch before the validation run — re-applying the one-liner restored md521966A07066E0786F43ACD88F124F2B9. This demonstrates in practice why an upstream schema fix is the durable solution: local patches do not survive package updates.Proposed fix
Add the missing type so every client path serializes the argument as an object:
plugin: { + type: "object", required: true, oneOf: [{ type: "object", additionalProperties: false,md5 of
lib/index.js: beforeCF9D4CF4096378C1C14E6AA5343247D9→ after21966A07066E0786F43ACD88F124F2B9(verified on the local Windows installation).Notes
required: trueinside property schemas (nonstandard JSON Schema, but accepted by the host validator). The actionable defect here is only the missingtypeonplugin.dsh-tool-cordis0.1.1-rc.2 this was the only top-leveloneOfparameter; tools elsewhere in the broader schema dialect should be checked for the same missing parameter-leveltype.node_modules. An upstream schema fix is the durable solution.deepseek-ai/deepseek-harness(perpackage.json→repository, directoryapps/cli); the defect lives in the@deepseek-ai/dsh-tool-cordispackage.Requested upstream action
type: "object"alongsideoneOfin the schema dialect handling (or teach the web-process adapter to coerce/parse typelessoneOfparameters).All reactions