Skip to content

fix: avoid redeclaring WP-CLI global --user in mcp serve #328

Open

Description

@chubes4

Problem

mcp serve declares --user as a command option while WP-CLI already reserves --user as a global bootstrap option. Registering the command causes a conflicting-global-argument warning before unrelated command output.

Synthetic reproduction

With the adapter active, run:

wp help mcp serve

Expected: command registration emits no global-argument collision warning.

Actual: the command-owned --user synopsis collides with WP-CLI's global option.

Suggested direction

Rely on WP-CLI's global --user context, or rename the command-specific option and preserve documented behavior with a registration-level regression test.

AI Assistance Disclosure

OpenCode, using openai/gpt-5.6-terra, directly orchestrated this report under Chris Huber's authorization.

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

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions