miguelgrinberg / APIFairy

A minimalistic API framework built on top of Flask, Marshmallow and friends.
MIT License
321 stars 30 forks source link

Quart Support #85

Open collinsmarra opened 6 months ago

collinsmarra commented 6 months ago

I like the way you write your APIs and I always use microblog-api as my inspiration. I recently came across Quart and I decided to use it and will probably be using it going on. I completed one project with Quart while using your 'style' and your extensions as Quart allows one to use some Flask extensions with recently quart_flask_patch and before quart.quart_flask_patch. But since upgrading to Quart>=0.19.0 some extensions like APIFairy are not compatible. I was wondering if there are plans to add quart support here or someone from the community can do it in a separate repisitory

miguelgrinberg commented 6 months ago

I don't have plans to support Quart at this time, sorry. My understanding is that most Flask extensions do not work well with Quart, so I'm surprised this one worked at all at some point.

collinsmarra commented 6 months ago

Also, Flask-HTTPAuth and Alchemical worked. Alchemical still works. I modified Flask-HTTPAuth to create Quart-HTTPAuth. I see APIFairy use Flask-HTTPAuth so maybe that will be a good start,

miguelgrinberg commented 6 months ago

Alchemical is framework agnostic and has native support for asyncio, so yes, that should work just fine not only with Quart but also with FastAPI or any other async framework.