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

Bug: The key of a List is included as an element of said list. #1283

Open
jlambright opened this issue Nov 28, 2023 · 3 comments
Open

Bug: The key of a List is included as an element of said list. #1283

jlambright opened this issue Nov 28, 2023 · 3 comments
Assignees

Comments

@jlambright
Copy link

Given the following object:
json { "metadata": <MetaDataModel>, "data": <List<TicketModel>> }

I'm seeing the key of the data list object be included in the list object itself. (See Screenshots Below.)

BuiltBug_KeyAsListElement
BuiltBug_KeyInList

@davidmorgan
Copy link
Collaborator

It's normal that that happens as part of the serialization process: there should always at some point be an Iterable that mentions the field name and then the value. It should however not get passed to the ListBuilder :)

It works in all the cases I know about ;) so I'll need more information to make any progress here please.

Is there any chance you can provide a small repro of the problem?

Thanks.

@jlambright
Copy link
Author

jlambright commented Nov 28, 2023

I'll need to check on how much I can share.

I should be able to get you the code generated by the OpenAPI Client Generator, as well as a sample of the JSON structure this is happening with.

Sincerely,
TechStop Josh 😉

@jlambright
Copy link
Author

jlambright commented Nov 28, 2023

Error: Expected a value of type 'Iterable<Object?>', but got one of type 'String'

I'm trying to get a minimal example that I can share with you. Unfortunately, there is a lot I have to prune out.

It should be noted that the error got suppressed somewhere along the line. I had to follow the logic path step-by-step, via IntelliJ Debug, in order to catch it.

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

No branches or pull requests

2 participants