softwaremill / sttp-apispec

OpenAPI, AsyncAPI and JSON Schema Scala models.
Apache License 2.0
23 stars 11 forks source link

Allow doc extensions to override model's default attributes #113

Closed hygt closed 1 year ago

hygt commented 1 year ago

See https://softwaremill.community/t/explicit-explode-true-in-the-generated-openapi/280/3

adamw commented 1 year ago

Seems there are some test failures

hygt commented 1 year ago

My bad, I didn't bother trying to deserialize the JSON. That is super weird, I don't see anything wrong, it's valid OpenAPI. I'll look into it.

hygt commented 1 year ago

OK @adamw I think I figured it out, the Parameter decoder was expecting examples and content fields and I believe that's a bug, see https://github.com/softwaremill/sttp-apispec/pull/113/files#diff-7eda956eb25bc05a87ae9d4bd8db486f99ba1621bc11037d83a8cf5604eb8100R90-R98

I wonder if this class can be simplified, naively I feel like the decoding of empty ListMaps should be the same everywhere?

adamw commented 1 year ago

Yes I think this looks good, thanks :)