-
Notifications
You must be signed in to change notification settings - Fork 59
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
FORBIDDEN_ADDITIONAL_PROPERTIES_BY_DEFAULT and sealed classes #353
Comments
Hi @sanyarnd, I've added some basic support for the
|
Hi, thanks :) I agree it's kind of hard to support all cases, but anyOf is quite a valid usage, especially if we're talking about Kotlin and Java sealed classes. It'd be nice to not specify it manually and infer it from type info, but of course it's not a deal breaker, I can still do it myself. Btw, are you planning releasing a version with additionalProperties support? (#352) |
Hi @sanyarnd, That is exactly what I mean: don't specify the subtypes as As for the release, I'm not sure when I will find the time and whether it is actually acceptable as-is now. |
Hi "additionalProperties: false" is generated for the following class:
which leads to
Using such schema for validation produces:
I guess we shouldn't generate additionalProperties: false or have a built-in workaround (#352)?
Right now I'm bypassing it with
which effectively removes "additionalProperties: false", but perhaps there's a better solution
The text was updated successfully, but these errors were encountered: