[codex] require OpenCode release summaries#6
Conversation
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughThe PR converts OpenCode release diff summarization from a best-effort/optional step to a hard requirement. The script now exits with code 1 on missing environment variables or empty output, the workflow removes ChangesRelease Automation Hardening
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
Summary
--file.OPENCODE_API_KEY, OpenCode failures, empty summaries, and missing summary files fail the release job.continue-on-errorfrom the OpenCode generation and append steps so npm publish does not proceed when summary generation fails.Root cause
opencode-ai@1.17.9 run --fileaccepts an array of files. The previous argument order placed the prompt after--file, so the prompt was parsed as another file path and failed withFile not found: Summarize this release diff....Validation
npm testnpm pack --dry-runenv -u RELEASE_TAG_NAME -u OPENCODE_API_KEY node scripts/summarize-release-diff.mjsexits nonzero as expectedSummary by CodeRabbit
New Features
Bug Fixes
Greptile Summary
This PR makes OpenCode release summaries required for publishing. The main changes are:
CHANGELOG.mdin npm artifacts.Confidence Score: 3/5
Not yet safe to merge because the required release-summary step can fail under the default configuration.
The workflow hardening is directionally correct, but the default model used by the required summary script is rejected by the configured OpenCode CLI version, blocking releases unless users manually override the model.
scripts/summarize-release-diff.mjs
What T-Rex did
Comments Outside Diff (1)
scripts/summarize-release-diff.mjs, line 6 (link)npm publish, but the defaultopencode/kimi-k2is rejected byopencode-ai@1.17.9withModel not found: opencode/kimi-k2. WhenOPENCODE_MODELis not set, the release job exits nonzero before publishing even thoughOPENCODE_API_KEYis configured. Use a currently accepted default model, or fail early with a clear message thatOPENCODE_MODELmust be set.Artifacts
Repro: runnable harness for executing the release summary script with OPENCODE_MODEL unset
Repro: terminal output showing opencode-ai rejects the default opencode/kimi-k2 model
Reviews (1): Last reviewed commit: "fix: include changelog in npm package" | Re-trigger Greptile