Skip to content

bug: mcpServers field incorrectly required #55

Description

@Smityz

Current Behavior

# This fails with ValidationError
request = NewSessionRequest(cwd="/tmp")
# Error: Field required [type=missing]

Expected Behavior

# Should work per spec
request = NewSessionRequest(cwd="/tmp")
request = NewSessionRequest(cwd="/tmp", mcp_servers=[])

https://github.com/agentclientprotocol/python-sdk/blob/main/src/acp/schema.py#L1339-L1345
https://github.com/agentclientprotocol/python-sdk/blob/main/src/acp/schema.py#L1987-L1993

Set the default for these two to None.

Reproduction steps

easy to Reproduction

Expected result

keep the same behavior with spec

Actual result

mcpServers field incorrectly required

Versions / environment

0.7

Logs & screenshots

Open to submitting a fix?

  • I’m willing to open a PR for this bug.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions