Bump pyo3 from 0.23.5 to 0.25.0
Type: Pull Request
State: Open
Association: Contributor
Comments: 1
(7 months ago)
(7 months ago)
part: dependencies lang: rust
Bumps pyo3 from 0.23.5 to 0.25.0.
Release notes
Sourced from pyo3's releases.
PyO3 0.25.0
This version extends Python version support to include the new Python 3.14, currently in beta. Please note it is possible that there may yet be changes to 3.14 before stable release which may impact final compatibility.
New optional dependencies on
bigdecimal,ordered_float, andtimehave been added to permit converting types from those crates to Python types (and vice versa).The
experimental-inspectfeature now has the capability to autogenerate type stubs. These stubs are still extremely basic and lack much information. Tooling such assetuptools-rustandmaturinwill also need to be updated to make adoption of these easier. Please follow PyO3/pyo3#5137 to keep abreast of developments of this feature.The
#[pyclass]macro has gained new options#[pyclass(generic)]and#[pyclass(immutable_type)]to offer additional control over the runtime behaviour of the generated Python type object.The
AsPyPointertrait has been removed as PyO3's smart pointer types such asPy<T>,Bound<T>andBorrowed<T>covered this use case with a better API.As part of the upgrade to support 3.14, there have also been many cleanups to
pyo3-ffi. Many definitions which are private implementation details of CPython have been removed; projects downstream of CPython cannot rely on stability of these even across CPython patch releases.There are also many other incremental improvements, bug fixes and smaller features.
Please consult the migration guide for help upgrading.
Thank you to everyone who contributed code, documentation, design ideas, bug reports, and feedback. The following contributors' commits are included in this release:
@0x676e67@bschoenmaeckers@clin1234@davidbrochart@davidhewitt@ddelange@decathorpe@dependabot[bot]@exg@hgmich@Icxolu@IvanIsCoding@m-ou-se@n-eq@ngoldbaum@Owen-CH-Leung@prutschman-iv@superserious-dev@Tpt@trim21@Vrajs16@xhochyPyO3 0.24.2
This is a small patch release containing minor bugfixes and documentation improvements, including an unused imports lint warning raised from inside PyO3's proc macros.
Thank you to the following contributors for the improvements:
... (truncated)
Changelog
Sourced from pyo3's changelog.
[0.25.0] - 2025-05-14
Packaging
- Support Python 3.14.0b1. #4811
- Bump supported GraalPy version to 24.2. #5116
- Add optional
bigdecimaldependency to add conversions forbigdecimal::BigDecimal. #5011- Add optional
timedependency to add conversions fortimetypes. #5057- Remove
cfg-ifdependency. #5110- Add optional
ordered_floatdependency to add conversions forordered_float::NotNanandordered_float::OrderedFloat. #5114Added
- Add initial type stub generation to the
experimental-inspectfeature. #3977- Add
#[pyclass(generic)]option to support runtime generic typing. #4926- Implement
OnceExt&MutexExtforparking_lot&lock_api. Use the new extension traits by enabling thearc_lock,lock_api, orparking_lotcargo features. #5044- Implement
From/IntoforBorrowed<T>->Py<T>. #5054- Add
PyTzInfoconstructors. #5055- Add FFI definition
PY_INVALID_STACK_EFFECT. #5064- Implement
AsRef<Py<PyAny>>forPy<T>,Bound<T>andBorrowed<T>. #5071- Add FFI definition
PyModule_Addandcompat::PyModule_Add. #5085- Add FFI definitions
Py_HashBuffer,Py_HashPointer, andPyObject_GenericHash. #5086- Support
#[pymodule_export]onconstitems in declarative modules. #5096- Add
#[pyclass(immutable_type)]option (on Python 3.14+ withabi3, or 3.10+ otherwise) for immutable type objects. #5101- Support
#[pyo3(rename_all)]support on#[derive(IntoPyObject)]. #5112- Add
PyRangewrapper. #5117Changed
- Enable use of
datetimetypes withabi3feature enabled. #4970- Deprecate
timezone_utcin favor ofPyTzInfo::utc. #5055- Reduce visibility of some CPython implementation details: #5064
- The FFI definition
PyCodeObjectis now an opaque struct on all Python versions.- The FFI definition
PyFutureFeaturesis now only defined up until Python 3.10 (it was present in CPython headers but unused in 3.11 and 3.12).- Change
PyAnyMethods::isto takeother: &Bound<T>. #5071- Change
Py::isto takeother: &Py<T>. #5071- Change
PyVisit::callto takeT: Into<Option<&Py<T>>>. #5071- Expose
PyDateTime_DATE_GET_TZINFOandPyDateTime_TIME_GET_TZINFOon PyPy 3.10 and later. #5079- Add
#[track_caller]towith_gilandwith_gil_unchecked. #5109- Use
std::thread::park()instead oflibc::pause()orsleep(9999999). #5115Removed
- Remove all functionality deprecated in PyO3 0.23. #4982
- Remove deprecated
IntoPyandToPyObjecttraits. #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
AsPyPointertrait. #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
... (truncated)
Commits
ec1a350release: 0.25.0 (#5128)c4efb16ci: reduce verbosity & install zoneinfo backport on <3.9 (#5136)b61dc7faddrename_allsupport for#[derive(IntoPyObject)](#5112)d74fadcImplementOnceExt&MutexExtforparking_lot&lock_api(#5044)f87b286Don't expose PyASCIIObjectState on Python3.14 and newer (#5133)b36849amore format args inlining (#5135)5807d80Add#[pyclass(generic)](#4926)283ba3fFix clippy errors (#5134)3a39844AddPyRangewrapper (#5117)e613a79Implement optional featureordered-floatfor NotNan/OrderedFloat <-> Python...- Additional commits viewable in compare view
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
@dependabot rebasewill rebase this PR@dependabot recreatewill recreate this PR, overwriting any edits that have been made to it@dependabot mergewill merge this PR after your CI passes on it@dependabot squash and mergewill squash and merge this PR after your CI passes on it@dependabot cancel mergewill cancel a previously requested merge and block automerging@dependabot reopenwill reopen this PR if it is closed@dependabot closewill close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually@dependabot show <dependency name> ignore conditionswill show all of the ignore conditions of the specified dependency@dependabot ignore this major versionwill close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this minor versionwill close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this dependencywill close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Pull Request Statistics
0
0
+0
-0
Package Dependencies
Technical Details
| ID: | 1176441 |
| UUID: | 3106473430 |
| Node ID: | PR_kwDOJy3j7s6YcR6Q |
| Host: | GitHub |
| Repository: | python-project-templates/python-template-rust |