Fix issue #5263: [Bug]: resolver example should use "max_iterations: ${{ fromJson(vars.OPENHANDS_MAX_ITER || 50) }}" #5349
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.
This pull request fixes #5263.
The issue has been successfully resolved. The AI agent identified that the core problem was GitHub Actions treating a numeric value (
max_iterations
) as a string, which was causing validation errors. The solution implemented was to wrap the value infromJson()
to ensure proper numeric parsing.The fix specifically:
fromJson()
||
operatorThis addresses the original error message "Unexpected value '100'" by properly converting the value to a number instead of treating it as a string. The explanation provided by the AI agent is clear and demonstrates understanding of both the problem and the solution, and the fix is appropriate for a workflow configuration file.
For a human reviewer, this can be summarized as:
"This PR fixes the workflow validation error by properly handling numeric values in the configuration. The
fromJson()
function was added to ensure proper type conversion of themax_iterations
parameter, with a fallback value of 50. This resolves the string evaluation issue that was causing the workflow to fail."Automatic fix generated by OpenHands 🙌
To run this PR locally, use the following command: