Skip to content

[Bug] MCP config migration fails silently after upgrade - confusing error messages on Windows #790

@FranFkntastic

Description

@FranFkntastic

What version of Kimi Code CLI is running?

1.3

Which open platform/subscription were you using?

moderato

Which model were you using?

kimi-for-coding

What platform is your computer?

Microsoft Windows NT 10.0.19045.0 x64

What issue are you seeing?

After upgrading kimi-cli (via uv tool upgrade kimi-cli), the tool crashes immediately on startup with cryptic error messages instead of providing clear guidance about MCP config migration.

What steps can reproduce the bug?

  1. Install older version of kimi-cli with MCP server configured using httpUrl
  2. Upgrade kimi-cli to v1.3
  3. Run kimi
  4. Tool crashes with OSError(22, 'Incorrect function') instead of clear MCP validation error

What is the expected behavior?

  • Auto-migrate old httpUrl format to new url format, OR
  • Show clear error: Invalid MCP config: field 'httpUrl' is deprecated, use 'url' instead, OR
  • Provide migration command or documentation link

Additional information

Workaround:
Manually edit ~/.kimi/mcp.json, rename field:

{
"mcpServers": {
"context7": {

  • "httpUrl": "https://mcp.context7.com/mcp",
    
  • "url": "https://mcp.context7.com/mcp",
    "headers": { ... }
    
    }
    }
    }

Additional context:

The error handler itself crashed while trying to report the MCP validation error
This is a breaking change in config schema without major version bump
MCP servers are becoming popular - other users will hit this
The README shows new format (url) but doesn't mention migration from old format (httpUrl)

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