Repository navigation
Link posts survive a malformed model reply - #161
Merged
Merged
Conversation
Prod's gpt-4o-mini answered for https://outreachgraph.com/ with a stray } after the Reddit post; the strict JSON.parse dropped all four posts and the API returned 502 draft_failed. Each {"network": ...} object is now parsed separately when the whole reply is not valid JSON. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Merged
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.
Verifying #159 live: drafting from https://outreachgraph.com/ returned 502 draft_failed. Prod's gpt-4o-mini replied with four good posts and one stray
}after the Reddit object, and the strict JSON.parse threw all four away. When the whole reply is not valid JSON, each{"network": ...}object is now parsed on its own (string-aware brace matching), so one bad brace costs at most its own post. Regression test uses that reply's shape.🤖 Generated with Claude Code