Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

no default JsonSchemaValidatorSupplier or default McpJsonMapper in mcp-json project #574

Copy link
Copy link
@scottslewis

Description

@scottslewis
Issue body actions

As per bug #562 I'm also getting these exceptions when running the latest 0.14.0 in repo (not deployed yet).

java.lang.IllegalStateException: No default JsonSchemaValidatorSupplier implementation found
at io.modelcontextprotocol.json.schema.JsonSchemaInternal.lambda$createDefaultValidator$2(JsonSchemaInternal.java:66)
at java.base/java.util.Optional.orElseThrow(Optional.java:403)
at io.modelcontextprotocol.json.schema.JsonSchemaInternal.createDefaultValidator(JsonSchemaInternal.java:61)
at io.modelcontextprotocol.json.schema.JsonSchemaInternal.getDefaultValidator(JsonSchemaInternal.java:30)
at io.modelcontextprotocol.json.schema.JsonSchemaValidator.getDefault(JsonSchemaValidator.java:61)
at io.modelcontextprotocol.server.McpServer$SingleSessionAsyncSpecification.build(McpServer.java:232)
at ...

and

java.lang.IllegalStateException: No default McpJsonMapper implementation found
at io.modelcontextprotocol.json.McpJsonInternal.lambda$createDefaultMapper$2(McpJsonInternal.java:67)
at java.base/java.util.Optional.orElseThrow(Optional.java:403)
at io.modelcontextprotocol.json.McpJsonInternal.createDefaultMapper(McpJsonInternal.java:62)
at io.modelcontextprotocol.json.McpJsonInternal.getDefaultMapper(McpJsonInternal.java:30)
at io.modelcontextprotocol.json.McpJsonMapper.getDefault(McpJsonMapper.java:97)
at io.modelcontextprotocol.server.McpServer$SingleSessionSyncSpecification.build(McpServer.java:818)
at ...

This problem does not appear to me to be an OSGi problem as when I look in the mcp-json project there does not appear to be any META-INF/services/* files. I can see that the ServiceLoader is used in io.modelcontextprotocol.json.schema.JsonSchemaInternal line 41, and in io.modelcontextprotocol.json.McpJsonInternal line 45, so I suspect that the META-INF/services/* files in mcp-json were accidently not checked in.

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.