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
My understanding is odata.type is only required in the case the type cannot be determined such as it being a type derived from the specified type.
When using EnableDiscriminatorValue = true I get correctly odata.type used as a discriminator when a type has a derived type.
I also get however for seemingly all types, odata.type included as a required property.
Assemblies affected
v1.1.0
Steps to reproduce
Create an odata model with no derived types.
Generate an Open API specification from the model with EnableDiscriminatorValue = true.
Expected result
I would only expect odata.type to be required in the case a type is a derived type.
Actual result
odata.type is set as required for all types.
If I use Open API connected services in Visual Studio with the specification to generate a client, the client will fail to deserialize responses missing the required property by default.
Additional detail
This can be worked around in most case.
The text was updated successfully, but these errors were encountered:
My understanding is odata.type is only required in the case the type cannot be determined such as it being a type derived from the specified type.
When using EnableDiscriminatorValue = true I get correctly odata.type used as a discriminator when a type has a derived type.
I also get however for seemingly all types, odata.type included as a required property.
Assemblies affected
v1.1.0
Steps to reproduce
Expected result
I would only expect odata.type to be required in the case a type is a derived type.
Actual result
odata.type is set as required for all types.
If I use Open API connected services in Visual Studio with the specification to generate a client, the client will fail to deserialize responses missing the required property by default.
Additional detail
This can be worked around in most case.
The text was updated successfully, but these errors were encountered: