-
Notifications
You must be signed in to change notification settings - Fork 222
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
[TypeScript] Add support for nested arrays (array of string arrays) #4549
Comments
Hi @joebalancioLP General context: multi-dimensional arrays are generally not supported for generation, meaning that kiota will never generate I'd have expected kiota to generate Have you tried generating other languages (CSharp/Go/Java) to see if you get a different result in the generated code? (not asking to run it for now) @andrueastman what's your opinion here? |
You're right, I think this is an edge case the KiotaBuilder should probably be updated to handle as an unknown type. I suspect it keeps trying to unwrap the type for the array to come up with type annotation. Ideally in this scenario, this should be generated as either
|
@baywet Thanks for triaging. I haven't tried generating in other languages since TypeScript is my only target for now. |
@andrueastman when you have some time can you investigate to see whether it's specific to TS or general to all languages at this point please? |
Validated this affects other languages as well as the Kiota Builder will recursively unwrap the |
Hey there. Running into an issue with the generated client. I have a schema where one of the properties is an array of string arrays. It is returned in an API response and it looks like the following:
When I make an API call using the generated client, I get this error:
The stacktrace points to the generated models. When I inspect the generated model, I see that the a few things are off.
The code fails during deserialization in this function. Looks like the wrong function is invoked
getCollectionOfPrimitiveValues
The schema is typed incorrectly. It should be
string[][]
Also I changed the OpenAPI spec a few different ways and here are my findings.
UntypedNode[]
{ "0": "updatedAt", "1": "DESC" }
The text was updated successfully, but these errors were encountered: