Skip to content
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

BUG Unable to deserialize OpenAPI Parameter #4689

Open
joyceli214 opened this issue Jun 4, 2024 · 0 comments
Open

BUG Unable to deserialize OpenAPI Parameter #4689

joyceli214 opened this issue Jun 4, 2024 · 0 comments

Comments

@joyceli214
Copy link

I was trying to convert json string to OpenAPI object and met below error:

Cannot deserialize value of type io.swagger.v3.oas.models.parameters.Parameter$StyleEnum from String "form": not one of the values accepted for Enum class: [MATRIX, SIMPLE, SPACEDELIMITED, FORM, DEEPOBJECT, LABEL, PIPEDELIMITED]

Then I tried to run below code (captured from ParameterDeSerializationTest.java) and also failed (threw same error).
final String json = "{\"in\":\"query\",\"style\":\"form\",\"required\":false,\"schema\":{\"type\":\"string\"}}";
final Parameter p = m.readValue(json, Parameter.class);

Is this a bug?

@joyceli214 joyceli214 changed the title Unable to deserialize OpenAPI Parameter BUG Unable to deserialize OpenAPI Parameter Jun 5, 2024
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

No branches or pull requests

1 participant