(no title)
Alir3z4 | 3 months ago
To be honest, I never liked the way async is done in python at all.
However, I love Django and Python in general. When I need "async" in a http cycle flow, I use celery and run it in background.
If client side needs to be updated about the state of the background task, the best is to send the data to a websocket channel known to the client side. Either it's Chat response with LLM or importing a huge CSV file.
Simple rule for me is, "don't waste HTTP time, process quick and return quick".
robertlagrant|3 months ago
SSE is nice.
revicon|3 months ago
Oxodao|3 months ago
bodhi_mind|3 months ago
I use a combination or channels and celery for a few projects and it’s works great.
pdhborges|3 months ago
vb-8448|3 months ago
but I still hope at some point they will manage to fix the devx with django/python and async
ActorNightly|3 months ago
With LLMS, you shit out working production ready web apps in 2 days now that are quite performant, as long as you don't care about code maintainability long term.
never_inline|3 months ago
Also performance wise FastAPI + uvicorn have many pitfalls as well, most of them being of asyncio.