Repository navigation
docs(readme): say the loop raises ModelError for unparseable tool calls - #37
Merged
folathecoder merged 1 commit intoNov 5, 2026
Merged
Conversation
Closes lunarstack-co#21 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
folathecoder
approved these changes
Nov 5, 2026
folathecoder
left a comment
Collaborator
There was a problem hiding this comment.
Looks great. Can you optionally star the project to support?
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.
Fixes #21
What changed
The README's error table said the loop raises
ModelOutputErrorfor unparseable tool calls. It doesn't. The loop asks the model to fix the call, and if it keeps sending broken calls it raisesModelError. I changed that one row to match what the code actually does. The first sentence and Retryable column stayed the same.ModelOutputTruncatedErroralready has its own row for calls cut off by the output limit, so I left that alone.REFERENCE.mddoesn't repeat the claim. There's no CHANGELOG line, since this only changes docs wording.How I tested it
ScriptedModelwith three turns of broken tool calls using{as the arguments.agent.runraisedModelErrorwith the message "Model produced unparseable tool calls on 3 consecutive turns", notModelOutputError.uv run pytest tests/test_readme.pypasses. I also changed the Retryable cell toyesto check if the test would catch it. It failed, so I changed it back.ruff check,ruff format --check, andmypypass. With one Windows test deselected, pytest reported 537 passed, 6 skipped.test_parallel_timeout_keeps_other_resultsfails on my Windows machine, but it also fails onmainbefore my change. The 0.01 s timeout might be related to Windows timing. I deselected it and left it unchanged.AI helped with
Drafted and checked with Claude Code; the run and the output are mine.