Fix update_api workflow failing on non-JSON AI changelog response - #596
Merged
Conversation
The 'Build changelog entries' step ran under bash -e. When the AI response wasn't valid JSON, jq exited with status 5, which killed the whole step instead of falling back to the default changelog entry. Also always logs the raw AI response for easier debugging. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Danger ReportNo issues found. |
Coverage Report for CI Build 32801311633Coverage remained the same at 90.971%Details
Uncovered ChangesNo uncovered changes found. Coverage RegressionsNo coverage regressions found. Coverage Stats
💛 - Coveralls |
dblock
added a commit
that referenced
this pull request
Aug 25, 2026
…y when missing Copilot CLI's response file can include narration/thinking lines before its final JSON answer (observed in run 32801440182), so the previous fix (#596) silently discarded a perfectly good AI-generated changelog because the whole file wasn't valid JSON. Instead, extract the last line that looks like a JSON object and parse just that. If no JSON object is found at all, fail the workflow visibly with ::error:: instead of silently falling back to the generic changelog entry. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
dblock
added a commit
that referenced
this pull request
Aug 25, 2026
…y when missing Copilot CLI's response file can include narration/thinking lines before its final JSON answer (observed in run 32801440182), so the previous fix (#596) silently discarded a perfectly good AI-generated changelog because the whole file wasn't valid JSON. Instead, extract the last line that looks like a JSON object and parse just that. If no JSON object is found at all, fail the workflow visibly with ::error:: instead of silently falling back to the generic changelog entry. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The scheduled
Update APIworkflow run 32789898905 failed at the "Build changelog entries" step with exit code 5.The step runs under
bash -e(GitHub Actions default). When the AI-generated changelog response isn't valid JSON,jqexits with status 5, which aborts the whole step instead of falling back to the defaultUpdate API from slack-api-ref@...entry.Fix
jqinvocation so a non-zero exit doesn't kill the step; falls back to the default entry as originally intended.