Skip to content

Troubleshooting

Start with the command that matches the failing surface, then inspect the effective settings and credentials.

Terminal window
kosmokrator --version
kosmokrator smoke:startup --json
kosmokrator config paths --json
kosmokrator settings:doctor --json

For source checkouts:

Terminal window
composer install
php vendor/bin/phpunit
php vendor/bin/pint --test
Terminal window
kosmokrator providers:list --json
kosmokrator providers:status --json
kosmokrator providers:status openai --json
kosmokrator settings:get agent.default_provider --json
kosmokrator settings:get agent.default_model --json
kosmokrator settings:options agent.default_model --provider openai --json

Common fixes:

SymptomFix
Missing API key`printf %s “$OPENAI_API_KEY”
Wrong default modelkosmokrator settings:set agent.default_model <model> --provider <provider> --json
OAuth provider not logged inkosmokrator providers:configure codex --device --json
Custom provider unreachableVerify providers:custom:list --json, URL, auth mode, and model ID.

Use explicit guards:

Terminal window
kosmokrator -p "Run tests" --max-turns 10 --timeout 600 --output-format stream-json

Checks:

SymptomFix
Needs an approval modalUse a policy that fits automation, or configure permissions.
Writes are deniedVerify --mode edit, tools.denied_tools, blocked paths, and permission mode.
Too many repeated tool callsCheck stream JSON for stuck detection nudges and lower task scope.
No session should be persistedAdd --no-session.
Terminal window
kosmokrator settings:get tools.default_permission_mode --json
kosmokrator settings:get tools.denied_tools --json
kosmokrator settings:get tools.blocked_paths --json
kosmokrator settings:get tools.allowed_paths --json

Remember:

  • denied_tools always wins.
  • Blocked paths always win unless explicitly allowed.
  • Plan and Ask modes remove write tools before permission evaluation.
  • Prometheus auto-approves governed calls, but does not bypass hard denies.
  • Integration and MCP read/write permissions are separate from native tool approval.
Terminal window
kosmokrator integrations:list --json
kosmokrator integrations:status --json
kosmokrator integrations:doctor plane --json
kosmokrator integrations:fields plane --json
kosmokrator integrations:schema plane.list_issues

Common fixes:

SymptomFix
Integration not activekosmokrator integrations:configure plane --enable --json
Missing credentialsUse integrations:fields then integrations:configure --set key=value.
Named account not foundPass --account <alias> consistently.
Write denied in headless modeSet write permission to allow or use --force only for trusted automation.
Function name unknownUse integrations:search <query> --json.
Terminal window
kosmokrator mcp:list --all --json
kosmokrator mcp:status --json
kosmokrator mcp:doctor --json
kosmokrator mcp:tools <server> --json

Common fixes:

SymptomFix
Project server is untrustedReview command, then run kosmokrator mcp:trust <server> --project --json.
Env token missing`printf %s “$TOKEN”
Tool discovery failsConfirm server command exists in PATH and can run outside KosmoKrator.
Tool treated as writeSet --read allow --write ask/allow explicitly; tools without readOnlyHint are conservative.
Config shape not detectedUse top-level mcpServers, or import compatible servers JSON with mcp:import.
Terminal window
kosmokrator web:providers --json
kosmokrator web:doctor --json
kosmokrator settings:list --category web --json

Common fixes:

SymptomFix
Search tool unavailablekosmokrator settings:set web.search.enabled on --json and restart.
Provider unconfiguredUse web:configure <provider> --api-key-env ... --enable.
External fetch unavailableSet web.fetch.allow_external to on and choose a provider.
Crawl unavailableSet web.crawl.enabled and choose Tavily or Firecrawl.
Terminal window
kosmokrator gateway:telegram:status --json
kosmokrator settings:list --category gateway --json
kosmokrator secrets:status gateway.telegram.token --json

Common fixes:

SymptomFix
Gateway disabledkosmokrator gateway:telegram:configure --enabled on --json
Missing tokenSet gateway.telegram.token or KOSMOKRATOR_TELEGRAM_BOT_TOKEN.
Bot ignores groupMention/reply to the bot, or configure free_response_chats.
Unauthorized chat/userCheck allowed_chats and allowed_users.
Terminal window
kosmokrator --renderer=ansi --no-animation
kosmokrator settings:set ui.renderer ansi --global --json

Checks:

SymptomFix
TUI rendering glitchesUse a modern terminal, or force ANSI.
Animation causes startup issuesUse --no-animation or set ui.intro_animated off.
Colors are unreadableTry ANSI mode and check terminal theme contrast.
Readline issues in remote shellForce --renderer=ansi.
Terminal window
cd website
npm ci
npm run build

If syntax highlighting or MDX fails, check fenced code blocks first. Astro/Starlight treats MDX as JSX, so raw < and { in prose sometimes need escaping or code fences.