You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Generate defaults for RequestWithDefaulttarget property.
What did you see instead?
Generate defaults for all schemas that uses Target instead.
I tried by setting with allOf but complains with Complex defaults error.
--- a/oas_defaults_gen.go+++ b/oas_defaults_gen.go@@ -4,24 +4,60 @@ package api
// setDefaults set default value of fields.
func (s *RequestA) setDefaults() {
+ {+ val := Target("default")+ s.Target.SetTo(val)+ }
The text was updated successfully, but these errors were encountered:
What version of ogen are you using?
v1.9.0
Can this issue be reproduced with the latest version?
Yes
What did you do?
We have an OpenAPI 3.1.0 schema shared that includes a regular expression to validate the input:
We use it in different schemas such as:
When we add a new schema where we want it to have a default value such as:
What did you expect to see?
Generate defaults for
RequestWithDefault
target
property.What did you see instead?
Generate defaults for all schemas that uses
Target
instead.I tried by setting with
allOf
but complains withComplex defaults
error.The text was updated successfully, but these errors were encountered: