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

Allow empty collections #70

mTatcher opened this issue Oct 13, 2015 · 2 comments


Copy link

commented Oct 13, 2015

When a fields.List is being parsed, it returns 'missing' if list is empty. Why not return empty list instead?


This comment has been minimized.

Copy link

commented Oct 14, 2015

In, parse_arg:

if (is_multiple(field) and not
    (isinstance(value, collections.Iterable) and len(value))):

len(value) is checking if value is an empty list.
I suggest removing this check


This comment has been minimized.

Copy link

commented Oct 14, 2015

@mTatcher Yes, I think and empty list should be returned if an empty list is passed from the client. That incorrect check appears to be a remnant from webargs' pre-marshmallow days.

Pull requests welcome!

@sloria sloria closed this in 545c525 Oct 16, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.