PyO3 0.9.0 Alpha.1
There are some breaking changes...
But I believe in most cases, you just change this
impl MyClass {
#[new]
fn new(init: &PyRawObject) {
init.init(MyClass {});
}
}to
impl MyClass {
#[new]
fn new() -> Self {
MyClass {}
}
}and everything works fine.
Please read the guide for detail.
CHANGELOG
Changed
- The blanket implementations for
FromPyObjectfor&Tand&mut Tare no longer specializable. ImplementPyTryFromfor your type to control the behavior ofFromPyObject::extract()for your types. - The implementation for
IntoPy<U> for TwhereU: FromPy<T>is no longer specializable. Control the behavior of this via the implementation ofFromPy. #[new]does not takePyRawObjectand can reutrnSelf#683- Use
parking_lot::Mutexinstead ofspin::Mutex#734
Added
- Implemented
IntoIteratorforPySetandPyFrozenSet. #716 PyClass,PyClassShell,PyObjectLayout,PyClassInitializer#683
Fixed
- Clear error indicator when the exception is handled on the Rust side. #719
- Fixed unsoundness of subclassing. #683.
Removed
PyRef,PyRefMut,PyRawObject#683