this post was submitted on 08 Apr 2024
20 points (100.0% liked)
Rust
6005 readers
5 users here now
Welcome to the Rust community! This is a place to discuss about the Rust programming language.
Wormhole
Credits
- The icon is a modified version of the official rust logo (changing the colors to a gradient and black background)
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I don't have an informed answer, and may be you know all of this already.
(I only used pyo3 once in one of my projects, and didn't know about this new experimental feature, I also only used it to call python code from Rust, which is the other half of the crate, so to speak.)
https://github.com/PyO3/pyo3/blob/main/guide/src/async-await.md
So the runtime here is from the python side. And my first guess would be that support doesn't extend to use-cases where special (Rust) runtime support is needed, like the typical io (and sometimes time) features of the tokio runtime that are often used.
Maybe the reference to "Other Python async runtime" in the quote above is hinting at something that may support such use-cases in the future.
If your Rust code doesn't work without using one of the
enable_()
methods here, then, that's probably your answer.