-
Notifications
You must be signed in to change notification settings - Fork 9.7k
Open
Description
Bug
The Filesystem MCP server extension bundled with Claude Desktop (macOS) ships a compiled dist/path-utils.js that contains a bug already fixed in the source.
The bug
normalizePath("/") returns "" (empty string), causing the server to crash on startup with:
Error accessing directory : Error: ENOENT: no such file or directory, stat ''
Root cause
The installed extension (version 2025.8.21) has the old regex in dist/path-utils.js:
return p.replace(/\/+/g, '/').replace(/\/+$/, '');This strips the trailing slash from /, producing an empty string.
Already fixed in source
The current TypeScript source (src/filesystem/path-utils.ts) uses a negative lookbehind that correctly preserves /:
return p.replace(/\/+/g, '/').replace(/(?<!^)\/$/, '');There are even existing tests for this case:
expect(normalizePath('/')).toBe('/');
expect(normalizePath('///')).toBe('/');Steps to reproduce
- Install the Filesystem MCP server extension in Claude Desktop (macOS)
- Add
/as an allowed directory - Restart Claude Desktop
- Server crashes immediately — visible in
~/Library/Logs/Claude/mcp-server-Filesystem.log
Expected
The extension should ship a build that includes the root path fix from the source.
Environment
- Claude Desktop on macOS (Darwin 25.3.0, Apple Silicon)
- Extension:
ant.dir.ant.anthropic.filesystem - Installed
@modelcontextprotocol/server-filesystemversion:2025.8.21 - Upstream source version:
0.6.3
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels