async function ?
(Im using a package that has a non async function and I have to use await in that function)
can't
So what should I do ? I googled that and someone said that I should create a new tokio runtime for that although tokio will not allow nested runtimes
you could spawn a task
finally found it ! using async_std crate would be something like this ✅ async_std::task::block_on(async { let track = track.unwrap(); println!("{:?}", track.id().await); });
Обсуждают сегодня