Problem generating model(s) when schema has type: object with oneOf with single ref referring to component using allOf #5921
Labels
Csharp
Pull requests that update .net code
status:waiting-for-triage
An issue that is yet to be reviewed or assigned
type:bug
A broken experience
WIP
What are you generating using Kiota, clients or plugins?
API Client/SDK
In what context or format are you using Kiota?
Nuget tool
Client library/SDK language
Csharp
Describe the bug
This is similar issue as #5808 where the contract we received has
oneOf
hierarchies where there is only a single ref underoneOf
but the schema had type: object set. If the type: object is set, the contract does not generate the expected models.Expected behavior
Kiota generates code for both schemas, with or without
type: object
.How to reproduce
I have a repository with the generated client and example schema which reproduce the issue available:
Open API description file
https://github.com/vipentti/kiota-type-object-one-of-issue/blob/main/DiscriminatorProblemSampleHierarchy.yaml
Kiota Version
1.21.0+ec3a3fff9fc6e2fb7de190d37969fa2e93aefdf5
Latest Kiota version known to work for scenario above?(Not required)
No response
Known Workarounds
No response
Configuration
Debug output
Click to expand log
Other information
Continuation of issue #5808 which was fixed by #5827.
The text was updated successfully, but these errors were encountered: