When a command fails with the --json flag, errors are returned as plain text instead of structured JSON. For example:
specter destroy nonexistent --json --yes
# Returns: agent 'nonexistent' not found in local state
# Should return: {"error": "agent 'nonexistent' not found in local state"}
This breaks the agent-native promise. Any AI agent parsing --json output will get unexpected plain text on errors.
When a command fails with the
--jsonflag, errors are returned as plain text instead of structured JSON. For example:This breaks the agent-native promise. Any AI agent parsing
--jsonoutput will get unexpected plain text on errors.