Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

All notable changes to this project will be documented in this file.

## [0.4.1] - 2026-11-12

### Fixed

- **The LPM CLI installs the package again.** Since MCP SDK 1.32.2, `lpm mcp serve` in LPM CLI releases before 0.86.0 failed to install this package, with "cannot derive peer \"zod\"". The SDK takes zod as both a dependency and a peer, and this package's narrower range resolved a second zod, which the LPM CLI's linker refuses. This package now asks for zod with the SDK's range, `^3.25 || ^4.0`, and runs on zod 4, so those releases start the server and see that it is retired.

## [0.4.0] - 2026-11-12

This is the last release. The LPM CLI serves MCP itself from version 0.86.0, as `lpm mcp serve`; run `lpm mcp setup` to move your editors to it.
Expand Down
37 changes: 37 additions & 0 deletions lib/__tests__/manifest.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
import { readFileSync } from "node:fs"
import { createRequire } from "node:module"
import path from "node:path"
import { expect, it } from "vitest"

const manifest = JSON.parse(
readFileSync(new URL("../../package.json", import.meta.url), "utf8"),
)
const require = createRequire(import.meta.url)

// The SDK's exports map sends package.json to a nested build manifest.
function sdkManifest() {
let directory = path.dirname(
require.resolve("@modelcontextprotocol/sdk/server/mcp.js"),
)
for (;;) {
try {
const candidate = JSON.parse(
readFileSync(path.join(directory, "package.json"), "utf8"),
)
if (candidate.name === "@modelcontextprotocol/sdk") return candidate
} catch {}
const parent = path.dirname(directory)
if (parent === directory) throw new Error("MCP SDK manifest not found")
directory = parent
}
}

// LPM CLI releases before 0.86.0 install this package for `lpm mcp serve`.
// The LPM CLI's linker refuses a peer that has two installed versions, and
// the MCP SDK takes zod as both a dependency and a peer: a narrower zod range
// here resolves a second zod, and the install fails.
it("asks for zod with the range the MCP SDK asks for", () => {
const sdk = sdkManifest()
expect(sdk.peerDependencies.zod).toBe(sdk.dependencies.zod)
expect(manifest.dependencies.zod).toBe(sdk.dependencies.zod)
})
13 changes: 6 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@lpm-registry/mcp-server",
"version": "0.4.0",
"version": "0.4.1",
"description": "Retired: the LPM CLI serves MCP itself from 0.86.0 as `lpm mcp serve`. This last release hands off to it when installed.",
"author": "LPM <hello@lpm.dev> (https://lpm.dev)",
"repository": {
Expand Down Expand Up @@ -40,7 +40,7 @@
},
"dependencies": {
"@modelcontextprotocol/sdk": "^1.12.0",
"zod": "^3.24.0"
"zod": "^3.25 || ^4.0"
},
"optionalDependencies": {
"keytar": "^7.9.0"
Expand Down
Loading