Skip to content

Replace mcp-server dependency with mcp package#1

Open
faezs wants to merge 12 commits into
mainfrom
claude/switch-mcp-dependency-CHD9w
Open

Replace mcp-server dependency with mcp package#1
faezs wants to merge 12 commits into
mainfrom
claude/switch-mcp-dependency-CHD9w

Conversation

@faezs

@faezs faezs commented Dec 16, 2025

Copy link
Copy Markdown
Owner

No description provided.

- Update flake.nix to use github:Tritlo/mcp source
- Update dependencies in agda-mcp.cabal (mcp >= 0.3.0.0)
- Rewrite Main.hs to use MCPServer typeclass API
- Update Server.hs handlers to use new MCP.Types
- Update test files to use new Content/TextContent patterns
- Build project using nix build
- Run tests via nix flake checks
- Uses DeterminateSystems Nix installer and magic cache
The mcp library has strict version bounds that don't work with GHC 9.10.
This patch relaxes the bounds for bytestring, containers, text, warp,
time, and other dependencies to allow building with newer package versions.
Replace the manual cabal bounds patch with haskell-flake's built-in
jailbreak option, which is cleaner and more maintainable.
Updates lock file to reflect the switch from drshade/haskell-mcp-server
to Tritlo/mcp library.
- Server.hs: Import ContentBlock(..) instead of TextContentType(..)
  since TextContentType is a data constructor of ContentBlock
- FileEdit.hs: Make splitAt pattern match total by using case expression
  instead of irrefutable pattern binding
Import ContentBlock(..) instead of Content(..) since TextContentType
is a data constructor of ContentBlock.
- Hide MCP.Server.ServerState to avoid collision with AgdaMCP.Server.ServerState
- Use fromMaybe instead of maybe+id to avoid potential id ambiguity
- Add data-dir and data-files to cabal for test fixtures
- Update TestUtils and EditPersistenceSpec to use getDataDir
- This ensures test files are found in Nix builds
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants