sipeed/picoclaw · warning

MCP server ${server.name} requires a command.

Error message

MCP server ${server.name} requires a command.

What it means

Validation error thrown in handleSave (web/frontend/src/components/config/config-page.tsx:520) when an enabled stdio-type MCP server has an empty command after trimming. It is the stdio counterpart of the URL check: local process servers need the executable name, while URL/command fields are nulled out in the patch for remote servers and vice versa. Disabled servers (enabled=false) skip validation.

Source

Thrown at web/frontend/src/components/config/config-page.tsx:520

                  headers: buildStringMapMergePatch(
                    shouldValidateServer
                      ? parseJSONObjectField(
                          server.headersText,
                          `MCP server ${server.name} headers`,
                        )
                      : baselineHeaders,
                    baselineHeaders,
                  ),
                  command: null,
                  args: null,
                  env: null,
                  env_file: null,
                },
              ] as const
            }

            if (shouldValidateServer && server.command === "") {
              throw new Error(`MCP server ${server.name} requires a command.`)
            }

            const baselineEnv = baselineServer
              ? parseJSONObjectField(
                  baselineServer.envText,
                  `Saved MCP server ${server.name} env`,
                )
              : {}

            return [
              server.name,
              {
                ...deferredPatch,
                enabled: server.enabled,
                type: "stdio",
                command: server.command,
                args: parseMultilineList(server.argsText),
                env: buildStringMapMergePatch(

View on GitHub (pinned to 49183d7e8d)

Solutions

  1. Enter the executable to run, e.g. node, npx, uvx, or an absolute binary path
  2. Put flags and script paths in the args field, not the command field
  3. If the server is not ready, disable it — disabled stdio servers are exempt from the command check
Defensive patterns

Strategy: validation

Validate before calling

if (form.mcpServers.some((s) => s.type === "stdio" && s.enabled && s.command.trim() === "")) {
  setFieldError("Enabled stdio MCP servers require a command.")
  return
}

Try / catch

try {
  await handleSave()
} catch (err) {
  if (err instanceof Error) setError(err.message)
}

Prevention

When it happens

Trigger: Adding an enabled stdio server, entering a name and args but leaving the command empty, then saving; clearing the command of a saved stdio server.

Common situations: User fills 'args' (e.g. dist/index.js) before the command (e.g. node) and forgets the command; command field contains only spaces; user expects the URL field to matter for stdio servers.

Related errors


AI-assisted analysis of sipeed/picoclaw@49183d7e8d (2026-08-15). Data as JSON: /api/errors/7d8c7e2f4a1305a6. Report an issue: GitHub.