Skip to content

fix: robust JSON parsing in Iteration node #4603

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

hackice20
Copy link

This PR fixes a bug in the Iteration node where JSON input variables were not being parsed correctly. The node now robustly parses stringified JSON (including those with escape characters), allowing proper iteration over arrays and objects. This prevents errors when passing variables or JSON strings as input to the Iteration node.
How to test:
Pass a variable or stringified JSON array/object to the Iteration node’s input.
The node should correctly iterate over each element without JSON parsing errors.

@HenryHengZJ
Copy link
Contributor

can you give me a demo agentflow to replicate the error?

@hackice20
Copy link
Author

[BUG] Iteration Node is not parsing the Flow variable, it remains as a string. #4600

@hackice20
Copy link
Author

somebody aprove this sh*t

@hackice20 hackice20 closed this by deleting the head repository Jun 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants