fix(mcp): preserve tuple constraints in advertised schemas

Declare fixed tuple tails and lengths at the canonical boundary so client array validation accepts every tool. Preserve nonempty candidate constraints in managed and application comparisons. Add catalog-wide client checks and parser/schema parity coverage for both dialects and projection directions.

Fixes #3576
This commit is contained in:
morluto
2026-10-15 01:12:46 +08:00
parent 93e75bc8fe
commit 10aa74dfed
9 changed files with 262 additions and 14 deletions
@@ -70,7 +70,9 @@ export const compareApplicationVersionsInputSchema = z
})
.superRefine(validateApplicationVersionIdentities);
const candidateNodesSchema = z.tuple([nodeIdSchema]).rest(nodeIdSchema);
const candidateNodesSchema = z
.tuple([nodeIdSchema], nodeIdSchema)
.check(z.minLength(1));
const exactMatchSchema = z.strictObject({
status: z.literal("matched"),
basis: z.enum([