-
Notifications
You must be signed in to change notification settings - Fork 175
Open
Labels
MgmtThis issue is related to a management-plane library.This issue is related to a management-plane library.v3Version 3 of AutoRest C# generator.Version 3 of AutoRest C# generator.
Description
Bug Description
The .NET code gen doesn't support model faltten with 2 layers of extends in TypeSpec.
Sample link: https://github.com/Azure/azure-rest-api-specs/blob/897f19441a4cc240eba138296f31e50841a6b57f/specification/edgeorder/resource-manager/Microsoft.EdgeOrder/EdgeOrder/models.tsp#L1648
e.g.
@@flattenProperty(ProductLine.properties);
model ProductLine {
properties?: ProductLineProperties;
}
model ProductLineProperties extends CommonProperties {
products?: Product[];
}
model CommonProperties extends BasicInformation {
filterableProperties?: FilterableProperty[];
}
model BasicInformation {
displayName?: string;
...
}
The properties from BasicInformation and CommonProperties will missing in the generated class.
Expected Behavior
All the properties from BasicInformation and CommonProperties models get generated in ProductLine class.
Actual Behavior
Only one property: products is generated.
Metadata
Metadata
Assignees
Labels
MgmtThis issue is related to a management-plane library.This issue is related to a management-plane library.v3Version 3 of AutoRest C# generator.Version 3 of AutoRest C# generator.