wI2L / fizz

:lemon: Gin wrapper with OpenAPI 3 spec generation
https://pkg.go.dev/github.com/wI2L/fizz
MIT License
214 stars 52 forks source link

Are Schema's anyOf/allOf/oneOf incorrectly typed? #109

Open c-wygoda opened 9 months ago

c-wygoda commented 9 months ago

These must be arrays according to the spec https://json-schema.org/draft/2020-12/json-schema-core#section-10.2.1.3, but aren't?

https://github.com/wI2L/fizz/blob/fe54d355ba0184693a3dd34eeacfe1a03487dff1/openapi/spec.go#L156-L158

I'm trying to inline the GeoJSON spec from an JSON file, but unmarshalling fails due to this.

Would be interested to hear about the reasons if this is deliberate.