-
Notifications
You must be signed in to change notification settings - Fork 87
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
Incorrect generation of free-form objects #1221
Comments
Bump. I got stung by this one too using latest OGEN, would be great to see a fix. |
Current validator/decoder behavior matches expected by JSON Schema. ogen generates #1246 fixes this issue in slighty different way: @ernado Thoughts? |
Let's generate Also let's keep our default unchanged (do not generate |
OpenAPI Guide states that
additionalProperties: true
is the default when a schema consists of justtype: object
, but the generated code ends up with astruct{}
type unlessadditionalProperties: true
is specified.What version of ogen are you using?
v1.0.1-0.20240411144324-e1628ac9f35f
Can this issue be reproduced with the latest version?
Yes
What did you do?
Changed schema from:
to:
What did you expect to see?
Generated code should be the same.
What did you see instead?
Without
additionalProperties
:With
additionalProperties
:The text was updated successfully, but these errors were encountered: