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

Use Iterable instead of List for array request parameters #842

Closed
provokateurin opened this issue Sep 24, 2023 · 6 comments
Closed

Use Iterable instead of List for array request parameters #842

provokateurin opened this issue Sep 24, 2023 · 6 comments
Labels
feature New feature or request package: dynamite

Comments

@provokateurin
Copy link
Member

Makes it a bit easier to work with since List adds some unnecessary restrictions.

@provokateurin provokateurin added feature New feature or request package: dynamite labels Sep 24, 2023
@Leptopoda
Copy link
Member

We need to look out for the serializers and their registered builders when changing the types.

@provokateurin
Copy link
Member Author

Yeah, I think this doesn't actually make a lot of sense. If we allow passing any iterable we still need to do the conversion somewhere. Better to let the consumer handle it instead of the library. What do you think?

@Leptopoda
Copy link
Member

I think the easiest way would be to just use built_collection throughout the framework.

They are immutable and usually less error prone (immutable -> no side effects)

@provokateurin
Copy link
Member Author

Agreed, but I remember there was a problem when we used them in our parameters when we used BuiltList instead of List. I think it had something to do with default values 🤔

@Leptopoda
Copy link
Member

#1292 will switch to BuiltList and after #1278 we will no longer support non built_collection values.
I don't think that this issue makes sense.

@provokateurin
Copy link
Member Author

Agreed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request package: dynamite
Projects
None yet
Development

No branches or pull requests

2 participants