0xDEADBEEFCAFE

joined 2 years ago
[–] 0xDEADBEEFCAFE@programming.dev 2 points 2 years ago (1 children)

That's a bummer. I guess what I though was PyO3 type hints was actually just PyCharm guessing at the types.

I tried creating a .pyi file and it seems to be a pretty big improvement over no type hints, but I don't know how to add type hints for modules added with PyModule::add_module and adding the .pyi file seems to make the type checker not know about my other modules.

Would you mind sharing the script for auto generating type hints? Keeping them in sync manually would be pretty annoying.

[–] 0xDEADBEEFCAFE@programming.dev 6 points 2 years ago (3 children)

How is the quality of the generated bindings?

I have previously used PyO3 for Python bindings and it doesn't seem to correctly generate type hints.

view more: ‹ prev next ›