Re:New Python REST API and CLI micro-framework
by gsibble on Friday February 19, 2016 @11:05AM
(#11134294)
I would argue that it handles requests twice as fast because it contains about half as many features. And I've added automatic documentation to many of my flask projects. Not knocking on your excellent project, just suggesting you stop knocking on Flask, which is an excellent wsgi server.
Re:New Python REST API and CLI micro-framework
by timothycrosley on Friday February 19, 2016 @11:33AM
(#11134491)
Hug contains the features flask contains. I haven't and I don't think you will in this entire thread see a single example of someone actually pointing a feature missing in hug that is relevant for APIs (not HTML websites like Jinja)
Re:New Python REST API and CLI micro-framework
by kstrauser on Friday February 19, 2016 @11:31AM
(#11134467)
Likewise. Flask surely isn't the end-all, be-all of web frameworks, but I've added autodocs to it for a past employer that included full autodiscovery. It's not exactly trivial but it's far from difficult.
Highlights:
- Automatic documentation - Type annotation based validation and transformation of input fields - Directives to inject more data (like request data) into existing functions in a safe and reusable way - It's easily twice as fast at handling requests as Flask, making Flask a rather horrible base for any competitor