Today's Python hot take: FastAPI is one of those sarcastic names, like Greenland (which isn't very green). The devs' claims of it being fast is some kind of joke. Because it's not actually very fast at all. A replacement package that's actually fast is Litestar, which also seems generally more wholesome.
The previous post with the hashtag #litestar is me praising it's sqlalchemy integration. Oh irony.
Last week I decided to pick #litestar instead of #fastapi for a new #python microservice and I already regret this decision. I can't make DB rollbacks work in tests because the test client runs the server in a separate thread with its own event loop. And it feels like I'm the first one doing it and there is no community to help.
I learned a valuable lesson: don't underestimate the importance of community. Sometimes, it's better to go with mainstream. Especially for commercial projects.
@glowrocks Django is still very much alive and I, unfortunately, work with it daily at my job. It didn't age well, though. The support for asyncio is still quite rough, support for typing is third-party (see django-stubs) and painful, and it hides too many things (the ORM makes it too easy to make bad requests). The modern most hyped web framework is #fastapi and I personally found #litestar (ex #starlite) quite nice (better #sqlalchemy integration).
#fastapi #LiteStar #starlite #sqlalchemy
Just for reference I'm running #LineageOS 13 on #DeepThought I tried a version 14 custom ROM, that I found but didn't like the lack of theming, so took it back to 13.
It runs well, and is very stable, so that's a bonus (:*
And now I've got #LiteStar / #StarLite I'll only be using DT for reading on.
#lineageos #deepthought #LiteStar #starlite
Think I've got most of the things I want on #LiteStar now, and as an added bonus some of the stuff no longer needs to be on #LuciferMorningstar so the phone is feeling just a little tiny bit empty (;*
First post from #OldFedilab on #LiteStar and I'm debating changing the name to #StarLite
#OldFedilab #LiteStar #starlite
First post from the new tablet, currently called #LiteStar but I may change that in the future (:*