8000 Update Rust crate pyo3 to 0.25.0 by renovate[bot] · Pull Request #36 · akrantz01/antsi · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Update Rust crate pyo3 to 0.25.0 #36

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 servi 8000 ce and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

renovate[bot]
Copy link
Contributor
@renovate renovate bot commented Mar 10, 2025

This PR contains the following updates:

Package Type Update Change
pyo3 dependencies minor 0.23.0 -> 0.25.0

Release Notes

pyo3/pyo3 (pyo3)

v0.25.0

Compare Source

Packaging
  • Support Python 3.14.0b1. #​4811
  • Bump supported GraalPy version to 24.2. #​5116
  • Add optional bigdecimal dependency to add conversions for bigdecimal::BigDecimal. #​5011
  • Add optional time dependency to add conversions for time types. #​5057
  • Remove cfg-if dependency. #​5110
  • Add optional ordered_float dependency to add conversions for ordered_float::NotNan and ordered_float::OrderedFloat. #​5114
Added
  • Add initial type stub generation to the experimental-inspect feature. #​3977
  • Add #[pyclass(generic)] option to support runtime generic typing. #​4926
  • Implement OnceExt & MutexExt for parking_lot & lock_api. Use the new extension traits by enabling the arc_lock, lock_api, or parking_lot cargo features. #​5044
  • Implement From/Into for Borrowed<T> -> Py<T>. #​5054
  • Add PyTzInfo constructors. #​5055
  • Add FFI definition PY_INVALID_STACK_EFFECT. #​5064
  • Implement AsRef<Py<PyAny>> for Py<T>, Bound<T> and Borrowed<T>. #​5071
  • Add FFI definition PyModule_Add and compat::PyModule_Add. #​5085
  • Add FFI definitions Py_HashBuffer, Py_HashPointer, and PyObject_GenericHash. #​5086
  • Support #[pymodule_export] on const items in declarative modules. #​5096
  • Add #[pyclass(immutable_type)] option (on Python 3.14+ with abi3, or 3.10+ otherwise) for immutable type objects. #​5101
  • Support #[pyo3(rename_all)] support on #[derive(IntoPyObject)]. #​5112
  • Add PyRange wrapper. #​5117
Changed
  • Enable use of datetime types with abi3 feature enabled. #​4970
  • Deprecate timezone_utc in favor of PyTzInfo::utc. #​5055
  • Reduce visibility of some CPython implementation details: #​5064
    • The FFI definition PyCodeObject is now an opaque struct on all Python versions.
    • The FFI definition PyFutureFeatures is now only defined up until Python 3.10 (it was present in CPython headers but unused in 3.11 and 3.12).
  • Change PyAnyMethods::is to take other: &Bound<T>. #​5071
  • Change Py::is to take other: &Py<T>. #​5071
  • Change PyVisit::call to take T: Into<Option<&Py<T>>>. #​5071
  • Expose PyDateTime_DATE_GET_TZINFO and PyDateTime_TIME_GET_TZINFO on PyPy 3.10 and later. #​5079
  • Add #[track_caller] to with_gil and with_gil_unchecked. #​5109
  • Use std::thread::park() instead of libc::pause() or sleep(9999999). #​5115
Removed
  • Remove all functionality deprecated in PyO3 0.23. #​4982
  • Remove deprecated IntoPy and ToPyObject traits. #​5010
  • Remove private types from pyo3-ffi (i.e. starting with _Py) which are not referenced by public APIs: _PyLocalMonitors, _Py_GlobalMonitors, _PyCoCached, _PyCoLineInstrumentationData, _PyCoMonitoringData, _PyCompilerSrcLocation, _PyErr_StackItem. #​5064
  • Remove FFI definition PyCode_GetNumFree (PyO3 cannot support it due to knowledge of the code object). #​5064
  • Remove AsPyPointer trait. #​5071
  • Remove support for the deprecated string form of from_py_with. #​5097
  • Remove FFI definitions of private static variables: _PyMethodWrapper_Type, _PyCoroWrapper_Type, _PyImport_FrozenBootstrap, _PyImport_FrozenStdlib, _PyImport_FrozenTest, _PyManagedBuffer_Type, _PySet_Dummy, _PyWeakref_ProxyType, and _PyWeakref_CallableProxyType. #​5105
  • Remove FFI definitions PyASCIIObjectState, PyUnicode_IS_ASCII, PyUnicode_IS_COMPACT, and PyUnicode_IS_COMPACT_ASCII on Python 3.14 and newer. #​5133
Fixed
  • Correctly pick up the shared state for conda-based Python installation when reading information from sysconfigdata. #​5037
  • Fix compile failure with #[derive(IntoPyObject, FromPyObject)] when using #[pyo3()] options recognised by only one of the two derives. #​5070
  • Fix various compile errors from missing FFI definitions using certain feature combinations on PyPy and GraalPy. #​5091
  • Fallback on backports.zoneinfo for python <3.9 when converting timezones into python. #​5120

v0.24.2

Compare Source

Fixed
  • Fix unused_imports lint of #[pyfunction] and #[pymethods] expanded in macro_rules context. #​5030
  • Fix size of PyCodeObject::_co_instrumentation_version ffi struct member on Python 3.13 for systems where uintptr_t is not 64 bits. #​5048
  • Fix struct-type complex enum variant fields incorrectly exposing raw identifiers as r#ident in Python bindings. #​5050

v0.24.1

Compare Source

Added
  • Add abi3-py313 feature. #​4969
  • Add PyAnyMethods::getattr_opt. #​4978
  • Add PyInt::new constructor for all supported number types (i32, u32, i64, u64, isize, usize). #​4984
  • Add pyo3::sync::with_critical_section2. #​4992
  • Implement PyCallArgs for Borrowed<'_, 'py, PyTuple>, &Bound<'py, PyTuple>, and &Py<PyTuple>. #​5013
Fixed
  • Fix is_type_of for native types not using same specialized check as is_type_of_bound. #​4981
  • Fix Probe class naming issue with #[pymethods]. #​4988
  • Fix compile failure with required #[pyfunction] arguments taking Option<&str> and Option<&T> (for #[pyclass] types). #​5002
  • Fix PyString::from_object causing of bounds reads whith encoding and errors parameters which are not nul-terminated. #​5008
  • Fix compile error when additional options follow after crate for #[pyfunction]. #​5015

v0.24.0

Compare Source

Packaging
  • Add supported CPython/PyPy versions to cargo package metadata. #​4756
  • Bump target-lexicon dependency to 0.13. #​4822
  • Add optional jiff dependency to add conversions for jiff datetime types. #​4823
  • Add optional uuid dependency to add conversions for uuid::Uuid. #​4864
  • Bump minimum supported inventory version to 0.3.5. #​4954
Added
  • Add PyIterator::send method to allow sending values into a python generator. #​4746
  • Add PyCallArgs trait for passing arguments into the Python calling protocol. This enabled using a faster calling convention for certain types, improving performance. #​4768
  • Add #[pyo3(default = ...'] option for #[derive(FromPyObject)] to set a default value for extracted fields of named structs. #​4829
  • Add #[pyo3(into_py_with = ...)] option for #[derive(IntoPyObject, IntoPyObjectRef)]. #​4850
  • Add FFI definitions PyThreadState_GetFrame and PyFrame_GetBack. #​4866
  • Optimize last for BoundListIterator, BoundTupleIterator and BorrowedTupleIterator. #​4878
  • Optimize Iterator::count() for PyDict, PyList, PyTuple & PySet. #​4878
  • Optimize nth, nth_back, advance_by and advance_back_by for BoundTupleIterator #​4897
  • Add support for types.GenericAlias as pyo3::types::PyGenericAlias. #​4917
  • Add MutextExt trait to help avoid deadlocks with the GIL while locking a std::sync::Mutex. #​4934
  • Add #[pyo3(rename_all = "...")] option for #[derive(FromPyObject)]. #​4941
Changed
  • Optimize nth, nth_back, advance_by and advance_back_by for BoundListIterator. #​4810
  • Use DerefToPyAny in blanket implementations of From<Py<T>> and From<Bound<'py, T>> for PyObject. #​4593
  • Map io::ErrorKind::IsADirectory/NotADirectory to the corresponding Python exception on Rust 1.83+. #​4747
  • PyAnyMethods::call and friends now require PyCallArgs for their positional arguments. #​4768
  • Expose FFI definitions for PyObject_Vectorcall(Method) on the stable abi on 3.12+. #​4853
  • #[pyo3(from_py_with = ...)] now take a path rather than a string literal #​4860
  • Format Python traceback in impl Debug for PyErr. #​4900
  • Convert PathBuf & Path into Python pathlib.Path instead of PyString. #​4925
  • Relax parsing of exotic Python versions. #​4949
  • PyO3 threads now hang instead of pthread_exit trying to acquire the GIL when the interpreter is shutting down. This mimics the Python 3.14 behavior and avoids undefined behavior and crashes. #​4874
Removed
  • Remove implementations of Deref for PyAny and other "native" types. #​4593
  • Remove implicit default of trailing optional arguments (see #​2935) #​4729
  • Remove the deprecated implicit eq fallback for simple enums. #​4730
Fixed
  • Correct FFI definition of PyIter_Send to return a PySendResult. #​4746
  • Fix a thread safety issue in the runtime borrow checker used by mutable pyclass instances on the free-threaded build. #​4948

v0.23.5

Compare Source

Packaging
Fixed
  • Fix thread-unsafe implementation of freelist pyclasses on the free-threaded build. #​4902
  • Re-enable a workaround for situations where CPython incorrectly does not add __builtins__ to __globals__ in code executed by Python::py_run (was removed in PyO3 0.23.0). #​4921

v0.23.4

Compare Source

Added
  • Add PyList::locked_for_each, which uses a critical section to lock the list on the free-threaded build. #​4789
  • Add pyo3_build_config::add_python_framework_link_args build script API to set rpath when using macOS system Python. #​4833
Changed
  • Use datetime.fold to distinguish ambiguous datetimes when converting to and from chrono::DateTime<Tz> (rather than erroring). #​4791
  • Optimize PyList iteration on the free-threaded build. #​4789
Fixed
  • Fix unnecessary internal py.allow_threads GIL-switch when attempting to access contents of a PyErr which originated from Python (could lead to unintended deadlocks). #​4766
  • Fix thread-unsafe access of dict internals in BoundDictIterator on the free-threaded build. #​4788
  • Fix unnecessary critical sections in BoundDictIterator on the free-threaded build. #​4788
  • Fix time-of-check to time-of-use issues with list iteration on the free-threaded build. #​4789
  • Fix chrono::DateTime<Tz> to-Python conversion when Tz is chrono_tz::Tz. #​4790
  • Fix #[pyclass] not being able to be named Probe. #​4794
  • Fix not treating cross-compilation from x64 to aarch64 on Windows as a cross-compile. #​4800
  • Fix missing struct fields on GraalPy when subclassing builtin classes. #​4802
  • Fix generating import lib for PyPy when abi3 feature is enabled. #​4806
  • Fix generating import lib for python3.13t when abi3 feature is enabled. #​4808
  • Fix compile failure for raw identifiers like r#box in derive(FromPyObject). #​4814
  • Fix compile failure for #[pyclass] enum variants with more than 12 fields. #​4832

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot force-pushed the renovate/pyo3-0.x branch from 9ca5d99 to c0e099a Compare May 14, 2025 13:08
@renovate renovate bot changed the title Update Rust crate pyo3 to 0.24.0 Update Rust crate pyo3 to 0.25.0 May 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants
0