yonaskolb / SwagGen

OpenAPI/Swagger 3.0 Parser and Swift code generator

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Bug?] SwagGen@4.3.1 not using Models' entity in response

cfiken opened this issue · comments

Hi @yonaskolb.
When I upgrade SwagGen from 4.2.0 to 4.3.1, I noticed that there are big differences in API.{API_NAME}.Response.
I made a reproducible repository and sample definition of openapi.yml.

In v4.2.0, the type of Response is SampleResponse, which is defined in Models.SampleResponse.

In v4.3.1, however, the type of Response is Status200 which is defined in the same file. Therefore the definition in Models.SampleResponse is not used here.

In this case the former v4.2.0 case is the behavior what I expected, but I couldn't figure out if the latter v4.3.1 is a SwagGen bug or a specification by openapi.yml definition.

Is this kind of bug? or just a mistake on my part?

ezoic increase your site revenue