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

arguments that can have value from a list of choices should not have collectionFormat in generated swagger docs #488

Open
deepakunni3 opened this issue Jul 6, 2018 · 0 comments

Comments

@deepakunni3
Copy link

flask-restplus version: 0.11

https://github.com/noirbizarre/flask-restplus/blob/master/flask_restplus/reqparse.py#L287

When you add an argument that can have a value from a list of choices, the type of the argument is string but the generated swagger docs indicate that the argument is a collectionFormat: multi.

According to Swagger 2.0 specification (https://swagger.io/docs/specification/2-0/describing-parameters/) collectionFormat is only applicable for type: array.

I ran across this when trying to validate a generated swagger.json

@deepakunni3 deepakunni3 changed the title parameters that can have value from a list of choices should be treated as string arguments that can have value from a list of choices should not have collectionFormat in generated swagger docs Jul 6, 2018
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

1 participant