Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix-get-parent-properties #2017

Merged
merged 6 commits into from
Sep 14, 2023
Merged

Conversation

qiaozha
Copy link
Member

@qiaozha qiaozha commented Sep 12, 2023

fixes #2014

@@ -943,3 +943,15 @@ export function hasPagingOperation(codeModel: ModularCodeModel) {
)
);
}

function getAllProperties(type: Type): Property[] {
const properties: Property[] = [];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: not sure this is caused the duplicated properties issues when discriminator property exists both parent and child model. see below cadl-ranch cases:

https://github.com/Azure/cadl-ranch/blob/main/packages/cadl-ranch-specs/http/type/model/inheritance/single-discriminator/main.tsp#L12-L25C1

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I found that, when I was trying to enable cadl ranch test cases for model inheritance in modular.

Copy link
Contributor

@MaryGao MaryGao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left small comments.

@qiaozha qiaozha merged commit edf93ed into Azure:main Sep 14, 2023
28 checks passed
@qiaozha qiaozha deleted the fix-get-parent-properties branch September 14, 2023 09:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[JS] Missing Property From Extension in Deserialize Method
2 participants