-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using Rust Futures from Python #4
base: main
Are you sure you want to change the base?
Conversation
I'm starting with an explanation of Python futures in Python, so we can expand on it to build a Rust awaitable that drives a Rust future. Is this making any sense? The fact that the two languages use the same denomination is a good sign for compatibility but makes the whole deal a bit confusing.
This look interesting 👀 |
Oh oops, I pushed my second commit here as well. I intended to make separate pull requests, but now that it's here... What do you prefer? That I change this PR's title or that I move my second paragraph to a different PR? |
This concludes my tutorial for writing the glue to use Rust futures from Python. From there it should be easy enough to write a library.
All right, so I decided to just leave everything in one big PR. I think this should be enough to explain the method I found, and to bootstrap any library that would like to implement something like this. |
Im happy to merge this if you're happy you got everything you need in it? |
Not just yet, I think I should remove the double callback from the examples as it's unneeded complexity. Have you had the time to read some of it? I know it's a bit long and I don't know if it makes it any clearer. |
It's ready. |
I'm starting with an explanation of Python futures in Python, so we can
expand on it to build a Rust awaitable that drives a Rust future.
Is this making any sense? The fact that the two languages use the same
denomination is a good sign for compatibility but makes the whole deal a
bit confusing.