Skip to content

fix(providers): mkdir opencode's config home before the render write (#1110) - #1112

Merged
rennf93 merged 1 commit into
feat/devops-agentfrom
fix/1110-opencode-config-home
Sep 21, 2026
Merged

rennf93 merged 1 commit into
feat/devops-agentfrom
fix/1110-opencode-config-home

Conversation

@rennf93

@rennf93 rennf93 commented Sep 21, 2026

Copy link
Copy Markdown
Owner

Stacked onto #1109 (merges into the devops PR, then rides it to slave).

Bug

Every OpenRouter-routed agent spawn exited 1 immediately: openrouter_cli_config.main() wrote opencode.json without creating ~/.config/opencode first, and the agent image never pre-creates that directory. Same crash on fe-dev-1, fe-pm, and the auditor. Fixes #1110.

Fix

main() now mkdir(parents=True, exist_ok=True)s the config parent before the write, mirroring what the bash-guard plugin write already did. Regression test renders into a nonexistent .config/opencode/ prefix.

Verification

…1110)

The agent image never pre-creates ~/.config/opencode, and main() wrote
opencode.json without mkdir-ing its parent, so every OpenRouter-routed
spawn exited 1 on FileNotFoundError before the CLI ever started (same
crash on fe-dev-1, fe-pm, the auditor). The bash-guard plugin write
already mkdir'd its parents; the config write now does the same.
Regression test mirrors the plugin-write parents test with a missing
.config/opencode prefix.
@github-actions

Copy link
Copy Markdown

Thanks for opening your first pull request on RoboCo!

Quick checklist before review (most of these are enforced by CI, but worth a glance):

  • make quality — ruff format check, ruff check, mypy, pytest (≥80% coverage), and the rest of the gate
  • Panel changes pass pnpm lint and pnpm exec tsc --noEmit (run from panel/)
  • No # noqa / # type: ignore shortcuts; pre-existing violations in touched files are fixed
  • Added an entry under ## [Unreleased] in CHANGELOG.md
  • Signed the CLA (the bot will prompt you on this PR)
  • Signed your commits — master requires verified signatures (SSH signing setup)
  • Updated any affected docs under docs/

See CONTRIBUTING.md for the full workflow and the Code of Conduct for the community standards we follow.

Welcome aboard — a maintainer will review shortly.

@rennf93
rennf93 merged commit 0e46a46 into feat/devops-agent Sep 21, 2026
4 checks passed
@github-project-automation github-project-automation Bot moved this from Backlog to Done in RoboCo Kanban Sep 21, 2026
@github-actions github-actions Bot locked and limited conversation to collaborators Sep 21, 2026
@rennf93 rennf93 self-assigned this Sep 25, 2026
@rennf93
rennf93 deleted the fix/1110-opencode-config-home branch September 25, 2026 22:40
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

tests Test suite changes

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant