pyo3
pyo3 copied to clipboard
Rust bindings for the Python interpreter
A few times now, I had to take in complex-ish Python data and convert it into an equivalent in Rust. `FromPyObject` already does the basic types, but I'd also like...
This is intended to fix #2072 - see further discussion in that thread. The implementation is such that for both `PyMapping` and `PyTryFrom`, they will call into python to check...
See https://github.com/PyO3/pyo3/pull/2314#issuecomment-1101761842 Ever since 3.11 was added to the workflow, it has been printing `Could not find platform dependent libraries `. I also get this warning locally (on Window) as...
Currently the exposed API for instantiate a warning in PyO3 is ```rust /// Issues a warning message. May return a `PyErr` if warnings-as-errors is enabled. pub fn warn(py: Python
### Bug Description These two functions use `catch_unwind` to catch panics and transfer them as Python exceptions (for `run_closure`) or just report them (for `drop_closure`). However, both functions drop the...
## 🐛 Bug Reports I am working for writing Python extension, but facing import submodule error. ``` ModuleNotFoundError: No module named 'supermodule.submodule'; 'supermodule' is not a package ``` ### What...
I've seen several questions about re-using `#[pyclass]` types between multiple Rust packages, for example on [gitter](https://gitter.im/PyO3/Lobby?at=5fdc8b47aa6bb528c3592ec1), [stack overflow](https://stackoverflow.com/questions/62686840/unable-to-use-types-between-multiple-rust-libraries-via-python-bindings-created) and most recently in #1418. This issue is indended to be a...
As discussed in #2337, I think the [`git-cliff`](https://github.com/orhun/git-cliff) tool might be a good way to easily deal with CHANGELOG management. To support my point, I created this PR with some...
Thank you for contributing to pyo3! Please consider adding the following to your pull request: - [x] an entry in CHANGELOG.md - ~~docs to all new functions and / or...
## 🐛 Bug Reports I can not link to the correct virtual environment in OS X. Instead, the system Python is always used. ### 🌍 Environment - Your operating system...