hpyproject / rust-hpy

Rust Python bindings with Hpy
10 stars 2 forks source link

Merge progress from module-init-functions branch #1

Open dralley opened 3 years ago

dralley commented 3 years ago

I was curious about contributing but the repo is empty. There's some progress in the module-init-functions branch, but it's totally unclear what state it's in - broken, incomplete, working but never merged, etc.

It would be great if this was changed, even if it's totally broken. Maybe document anything that was left undone or broken so that people can come along and contribute fixes.

hodgestar commented 3 years ago

@dralley Thank you for taking a look!

It seems that the module-init-function branch is only a start on a bridge from Rust to HPy extensions and was written when HPy was still only getting started and so is now quite far behind the current HPy master.

If you would like to take over from @gracinet I can get you commit access to the repository if you like. The broad approach would be something like:

We are planning to make the autogeneration used in HPy more re-usable by other HPy universal implementations (e.g. PyPy's one, Graal's one, this one).

It would also be good to get @gracinet's thoughts about where he wanted to take this and what he saw as the advantages and challenges if he has a moment.

gracinet commented 3 years ago

Hi!

Yes, it's proof-of-concept level code done during the 2020 PyPy winter sprint (very beginning of March), while others participants were hacking on HPy itself.

Unfortunately, I haven't hat any time to get back to it since then, and I'm not surprised if it's now far behind, given the activity HPy has seen in the mean time.

My general take on this is that HPy should become eventually the standard way to bind Python and Rust, of course. I'll have to get back to my notes to be more specific.

@hodgestar what you're saying about re-usability of the autogeneration looks to be a nice place to rebootstrap the Rust version.

I have no problem if someone takes over, I'm on an exciting project that should keep me 100% for the best part of 2021. Of course, I'd like to stay involved and would be happy to discuss things if there are people motivated to work on the Rust version.

dralley commented 3 years ago

I don't think I'm interested in being a permanent maintainer, just make some drive-by contributions. The rest of the information is good to know, thanks!

hodgestar commented 3 years ago

Drive by contributions are perfectly welcome. I am not a rust expert, but perhaps @gracinet and I can review.