-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Fix OpenApiJsonSchema array parsing #62051
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Comment inline about possibly adding coverage for custom converts that emit objects instead of arrays.
...NetCore.OpenApi.Tests/Services/OpenApiSchemaService/OpenApiSchemaService.ParameterSchemas.cs
Show resolved
Hide resolved
/backport to release/9.0 |
Started backporting to release/9.0: https://github.com/dotnet/aspnetcore/actions/runs/15282951411 |
@BrennanConroy backporting to "release/9.0" failed, the patch most likely resulted in conflicts: $ git am --3way --empty=keep --ignore-whitespace --keep-non-patch changes.patch
Applying: Fix OpenApiJsonSchema array parsing
Using index info to reconstruct a base tree...
M src/OpenApi/src/Schemas/OpenApiJsonSchema.Helpers.cs
M src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Services/OpenApiSchemaService/OpenApiSchemaService.ParameterSchemas.cs
Falling back to patching base and 3-way merge...
Auto-merging src/OpenApi/test/Microsoft.AspNetCore.OpenApi.Tests/Services/OpenApiSchemaService/OpenApiSchemaService.ParameterSchemas.cs
Auto-merging src/OpenApi/src/Schemas/OpenApiJsonSchema.Helpers.cs
CONFLICT (content): Merge conflict in src/OpenApi/src/Schemas/OpenApiJsonSchema.Helpers.cs
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config set advice.mergeConflict false"
Patch failed at 0001 Fix OpenApiJsonSchema array parsing
Error: The process '/usr/bin/git' failed with exit code 128 Please backport manually! |
Fixes #62023
We weren't reading before calling the recursive function which meant we'd never advance the
Utf8JsonReader
and always be in the statereader.TokenType == JsonTokenType.StartArray