Hacker News new | ask | show | jobs
by dhon_ 475 days ago
Could you elaborate on why using block_on wouldn't be an acceptable solution for users that want a blocking API?
2 comments

Why would I want to add tokio as a dependency if I don't use it?
Yes you're right. I'd assumed that tokio was used internally in the UI but from a cursory read it doesn't seem to be the case.
I was thinking of making it a opt-in feature, but I saw most of the usecases that I might have, might need concurrency and a runtime.
it definitely would be, that was my intention. By passing in a runtime you can either block or schedule. Giving you control on what you want to be concurrent and what you don’t.