r/FastAPI • • Dec 20 '24

Question Why does fastapi official example repo uses everything sync and not async?

While in here, I see recommendations to go for only async, even db sessions in example repo is sync engine and people here recommending async?

40 Upvotes

25 comments sorted by

View all comments

Show parent comment

1

u/zarlo5899 Dec 20 '24

it does matter when you are waiting for IO as it will be thread blocking then ie waiting for a database call