Changesets · Branches · Tags · Compare
| Changeset | 8fdd1cf6fd08aebd9632680ea498afe073d5cc61430cca1610fd7190355638de |
|---|---|
| Author | Nate Sesti <33237525+sestinj@users.noreply.github.com> · 2025-05-22 22:45 -07:00 |
| Committer | GitHub <noreply@github.com> · 2025-05-22 22:45 -07:00 |
| Parents | 7cf339d22ff0, a9863474fd9a |
3 files changed
modified core/config/yaml/loadYaml.ts +2 −2
| @@ -71,7 +71,7 @@ | ||
| 71 | 71 | command: server.command, |
| 72 | 72 | args: server.args ?? [], |
| 73 | 73 | env: server.env, |
| 74 | - }, | |
| 74 | + } as any, // TODO: Fix the mcpServers types in config-yaml (discriminated union) | |
| 75 | 75 | timeout: server.connectionTimeout, |
| 76 | 76 | }; |
| 77 | 77 | } |
| @@ -458,7 +458,7 @@ | ||
| 458 | 458 | transport: { |
| 459 | 459 | type: "stdio", |
| 460 | 460 | args: [], |
| 461 | - ...server, | |
| 461 | + ...(server as any), // TODO: fix the types on mcpServers in config-yaml | |
| 462 | 462 | }, |
| 463 | 463 | timeout: server.connectionTimeout, |
| 464 | 464 | })), |
modified extensions/vscode/package-lock.json +0 −0
Not shown: the file is larger than the hub shows, or this page holds as much as it shows. View the file.
modified packages/config-yaml/src/schemas/index.ts +5 −2
| @@ -9,13 +9,16 @@ | ||
| 9 | 9 | params: z.any().optional(), |
| 10 | 10 | }); |
| 11 | 11 | |
| 12 | +// TODO: This should be a discriminated union by type | |
| 12 | 13 | const mcpServerSchema = z.object({ |
| 13 | 14 | name: z.string(), |
| 14 | - command: z.string(), | |
| 15 | + command: z.string().optional(), | |
| 16 | + type: z.enum(["sse", "stdio"]).optional(), | |
| 17 | + url: z.string().optional(), | |
| 15 | 18 | faviconUrl: z.string().optional(), |
| 16 | 19 | args: z.array(z.string()).optional(), |
| 17 | 20 | env: z.record(z.string()).optional(), |
| 18 | - connectionTimeout: z.number().gt(0).optional() | |
| 21 | + connectionTimeout: z.number().gt(0).optional(), | |
| 19 | 22 | }); |
| 20 | 23 | |
| 21 | 24 | export type MCPServer = z.infer<typeof mcpServerSchema>; |