microsoft / microsoft/typespec
[Bug]: Typespec with multi-level discriminator models do not get generated in any SDK
- Dominant language
- Java
- Stars
- 5.9k
- Forks
- 394
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 104
Description
### Describe the bug
The Search team is using multi-level discriminators, but none of these models are getting generated in any of the four tier 1 SDKs (Python, .NET, Java, JS).
We have a planned release for 05/28. If there are workarounds, please let us know, as this is for //build
### Reproduction
https://github.com/Azure/azure-rest-api-specs/blob/8c26075af0a1d863cbd95267526d7b5d55e871dc/specification/search/data-plane/Search/models-knowledgebase.tsp#L389-L398
The above definition is not generating the intended model in the SDKs.
Another example: [here](https://github.com/Azure/azure-rest-api-specs/blob/8c26075af0a1d863cbd95267526d7b5d55e871dc/specification/search/data-plane/Search/models-knowledgebase.tsp#L444-L454)
Our client.tsp definition lives here -> [Search/client.tsp](https://github.com/Azure/azure-rest-api-specs/blob/main/specification/search/data-plane/Search/client.tsp)
### Checklist
- [x] Follow our [Code of Conduct](https://github.com/microsoft/typespec/blob/main/CODE_OF_CONDUCT.md)
- [x] Check that there isn't already an issue that request the same bug to avoid creating a duplicate.
- [x] Check that this is a concrete bug. For Q&A open a [GitHub Discussion](https://github.com/Microsoft/typespec/discussions).
- [x] The provided reproduction is a [minimal reproducible example](https://stackoverflow.com/help/minimal-reproducible-example) of the bug.
Contributor guide
Assessment
This issue has not been assessed yet.