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
{{ message }}
Repository navigation
Commit 4a4a175
Browse filesBrowse the repository at this point in the historyBrowse files
fix: [AI-6948] address PR review — preserve MCP config fields on disk writes
Resolves the review findings on the `/mcps` enable/disable persistence and
datamate transport sync paths.
- `mcp/config.ts`: `readMcpEntryFromDisk` now uses `getNodeValue` instead of a
manual children walk. `jsonc-parser` only populates `Node.value` for
primitives, so the old walk silently dropped `command` arrays and
`environment`/`headers` objects — corrupting local stdio (and remote-with-
headers) entries on the next write via `persistMcpEnabled`.
- `altimate/datamate-transport.ts`: same `getNodeValue` fix for the two sibling
walkers; preserve non-transport fields (`enabled`, `timeout`, `oauth`, …) when
rebuilding the synced datamate entry; widen the `**/mcp.json` ignore list
(`target`, `.next`, `out`, `vendor`, `coverage`, `.venv`, `.turbo`).
- `mcp/index.ts`: serialize `persistMcpEnabled` (promise chain) so concurrent
enable/disable can't interleave read-modify-write and clobber each other.
- `server/server.ts`: `reload-datamate` returns HTTP 500 (not 200) on error so
the extension can distinguish failure.
- `session/prompt.ts`: `/mcps enable|disable` validates the server name against
config and reports clearly when it's unknown (was silent).
- `test/mcp/config.test.ts`: add `readMcpEntryFromDisk` round-trip tests,
including the persist-enabled flow that previously corrupted local entries.
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
0 commit comments