Skip to main content

Crate block_on_place

Crate block_on_place 

Source
Expand description

§block-on-place

For when you want to call block_on() on a tokio::runtime::Handle but cannot 100% guarantee that you’re not inside of a runtime.

Internally, this uses task::block_in_place() to call Handle::block_on().

§Features

You can enable the tracing feature to get a warning when calling block_on_place() from within a runtime context.

Traits§

HandleExt
Extension trait for tokio::runtime::Handle which allows calling [block_on()] from within a runtime context.