Skip to content

Fix json-recursion error - #10

Draft
chinazhangchao wants to merge 1 commit into
win_rebase/v0.33.0from
chao/fixrecursion
Draft

chinazhangchao wants to merge 1 commit into
win_rebase/v0.33.0from
chao/fixrecursion

Conversation

@chinazhangchao

@chinazhangchao chinazhangchao commented Nov 19, 2026 •

Copy link
Copy Markdown
Collaborator

This pull request improves the testing of structured output validation by addressing recursion limit issues encountered during test collection on certain platforms. The main change is replacing the use of json.loads for deeply nested schemas with a direct dictionary construction to avoid exceeding platform-specific recursion limits.

Test stability improvements:

  • Added a new helper function _nested_array_schema_dict to build deeply nested JSON schema dictionaries directly, avoiding recursion limits during test collection.
  • Updated the test parameter in the pytest case from using json.loads(_nested_array_schema(2_000)) to _nested_array_schema_dict(2_000), ensuring compatibility with environments that have lower recursion limits.

Code cleanup:

  • Removed the unused import json statement from test_validation.py.

Signed-off-by: Chao Zhang <zhangchao@microsoft.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Signed-off-by:  <>
@chinazhangchao

Copy link
Copy Markdown
Collaborator Author

/ok to test debug-json-recursion ci=migrate-windows-github-actions

@shivamkumard-ctrl

Copy link
Copy Markdown
Collaborator

In reply to this comment by @chinazhangchao:

/ok to test debug-json-recursion ci=migrate-windows-github-actions

Started on 850d36fac8805ab6be29499b2df1d28422ae686e with CI branch migrate-windows-github-actions:

  • debug-json-recursion: pipeline 83529001

@shivamkumard-ctrl

Copy link
Copy Markdown
Collaborator

Windows CI (debug-json-recursion) on 850d36fac8805ab6be29499b2df1d28422ae686e, requested by @chinazhangchao: failure

Pipeline 83529001

Job Result Duration
test FAILED 10m 0s
build passed 43m 38s

Test suite debug-json-recursion: 0 passed, 0 failed, 0 skipped (collected 0, deselected 0).

Logs (private repo, access needed): https://github.com/shivamkumard-ctrl/vllm-windows-ci-logs/tree/main/on-demand/run-83529001-debug-json-recursion-850d36f

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