Jérôme Lafréchoux
Jérôme Lafréchoux
This is documented in [`handle_http_exception`](https://flask-smorest.readthedocs.io/en/latest/api_reference.html#flask_smorest.Api.handle_http_exception). But indeed the doc for `abort` is not helpful at all. So this is at least a doc issue. I'd rather keep the code as...
Perhaps you could play with schema context but it sounds too twisted. I won't be of much help as I'm not familiar with this feature. TBH, I think I'd do...
An alternative/complementary approach could be to add an examples section to the tests. This is a bit more advanced, since users must dig in the tests, but it ensures the...
Yeah, not sure how to put examples in the docs. There are sphinx features (perhaps extensions) to display the whole source code of a page in the docs. Could this...
Thanks for the report and investigation, and sorry for the delay. https://swagger.io/docs/specification/describing-request-body/ https://swagger.io/docs/specification/describing-request-body/file-upload/ AFAIU, apispec's mapping is correct for OAS2. When using OAS3, files and form should be sent as...
Ho @toonalbers. Thanks for your help on this. Here's a draft implementation: https://github.com/Nobatek/flask-rest-api/pull/83. It uses following mapping: - files: multipart/form-data - form: application/x-www-form-urlencoded Those are default values than can be...
Yes, I overlooked multipart. In fact, my implementation assumes there is only one request body parameter (only one parameter entered as json, form or files). IIUC, when using multipart, there...
Yes. Just to be sure, IIUC, we'd even need to merge arguments with location form and files if they both have the multipart content type.
I pushed more commits in https://github.com/Nobatek/flask-rest-api/pull/83 to add the `content_types` argument to the `arguments` decorator. (Plural because the user may specify several types, for instance several image types.) Feedback welcome....
Thanks @ssfdust. That's interesting. #83 is about correctly documenting resources. I'll limit its scope to that. But of course, it's only useful if this lib doesn't get in the way...