Expand description
async-std-runtime
PyO3 Asyncio functions specific to the async-std runtime
Items marked with <span class=“module-item stab portability” style=“display: inline; border-radius: 3px; padding: 2px; font-size: 80%; line-height: 1.2;”
unstable-streams
are only available when the unstable-streams
Cargo feature is enabled:
[dependencies.pyo3-async-runtimes]
version = "0.24"
features = ["unstable-streams"]
Modules§
- re_
exports attributes
re-exports for macros
Functions§
- future_
into_ py - Convert a Rust Future into a Python awaitable
- future_
into_ py_ with_ locals - Convert a Rust Future into a Python awaitable
- get_
current_ locals - Either copy the task locals from the current task OR get the current running loop and contextvars from Python.
- get_
current_ loop - Get the current event loop from either Python or Rust async task local context
- into_
future - Convert a Python
awaitable
into a Rust Future - local_
future_ into_ py Deprecated - Convert a
!Send
Rust Future into a Python awaitable - local_
future_ into_ py_ with_ locals Deprecated - Convert a
!Send
Rust Future into a Python awaitable - run
- Run the event loop until the given Future completes
- run_
until_ complete - Run the event loop until the given Future completes
- scope
- Set the task local event loop for the given future
- scope_
local - Set the task local event loop for the given !Send future
Attribute Macros§
- main
attributes
Provides the boilerplate for theasync-std
runtime and runs an async fn as main Enables an async main function that uses the async-std runtime.- test
attributes
testing
Registers anasync-std
test with thepyo3-asyncio
test harness Registers anasync-std
test with thepyo3-asyncio
test harness.