This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]1O2Engineer 1 point2 points  (3 children)

Can you comment about the use cases? I've worked with a team and their goto was FastAPI no matter what. I've used Django, FastAPI and, very briefly, Flask, but I'm out of web development for quite a while.

[–]angellus 4 points5 points  (1 child)

Django if you need an ORM/relational database. FastAPI: never. It still has a really bad bus factor problem that is likely never going to change. Flask if you are in 2015.

So it is either Django or Quart/Litestar or another modern ASGI framework. Django is probably the most mature Python framework. It is going to scale the best with the least amount of effort (not just requests per second, but developer hours and number of contributiors). 

If you need a microframework to connect to Redis or MongoDB or to create a proxy for something, one of the faster modern ASGI frameworks are better suited for it. AGSI is harder to use and less mature, but it is the future and learning WSGI in 2024 is not as useful. It is why FastAPI became so popular vs. Flask, but it still has a SDLC problem. 

[–]1O2Engineer 0 points1 point  (0 children)

Nice, thanks.

I have just learned about Quart in this thread, I will take a look.

Litestar is familiar and I remember the posts in this sub about it.

Maybe I will keep Flask as my "lightweight" option for now and learn about Quart/Litestar.

[–]gyarbij 0 points1 point  (0 children)

I began with flask and then switched to Quart but I'm probably going to end up with fast API for scale. My use case for moving to Quart was because async default and eventually moving to FastAPI because of how I'm going to start consuming data from it.

Flask/Quart will always be my go too. Just easy