Bump dependency versions and Rust edition#98
Merged
penberg merged 1 commit intotursodatabase:mainfrom Jul 28, 2025
Merged
Conversation
- Dependency Updates
- pyo3: 0.19.0 -> 0.25.1
- pyo3-build-config: 0.19.0 -> 0.25.1
- tokio: 1.29.1 -> 1.47.0
- tracing-subscriber: 0.3.18 -> 0.3.19
- Rust Edition 2021 -> 2024
- Migrated from GIL Refs to Bound API
- Replaced all GIL reference types with Bound smart pointers:
- &PyAny -> Bound<'_, PyAny>
- &PyList -> Bound<'_, PyList>
- &PyTuple -> Bound<'_, PyTuple>
- &PyModule -> &Bound<'_, PyModule>
- Updated Type Definitions
- Modified ListOrTuple enum to use Bound types and added #[derive(Clone)]
- Updated ListOrTupleIterator to return Bound<'py, PyAny> items
- API Method Updates
- Constructor methods: PyTuple::new_bound -> PyTuple::new, PyList::new_bound -> PyList::new
- Type access: py.get_type_bound -> py.get_type
- Added error handling for fallible constructors with ? operator
- Trait Implementation Changes
- FromPyObject: Migrated from extract to extract_bound method
- Conversion methods: Replaced into_py() and to_object() with into_pyobject().unwrap().into()
- Thread Safety
- Added unsafe impl Sync for both Connection and Cursor structs (required for PyO3 0.23+)
- Function Signatures
- Added explicit #[pyo3(signature = ...)] attributes for functions with trailing Option<T> parameters:
- execute and executemany: #[pyo3(signature = (sql, parameters=None))]
- fetchmany: #[pyo3(signature = (size=None))]
- __exit__: #[pyo3(signature = (exc_type=None, _exc_val=None, _exc_tb=None))]
- Module Initialization
- Updated pymodule function signature to accept &Bound<'_, PyModule> instead of &PyModule
Contributor
|
Thanks @kilian-hu! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Boundsmart pointers:&PyAny->Bound<'_, PyAny>&PyList->Bound<'_, PyList>&PyTuple->Bound<'_, PyTuple>&PyModule->&Bound<'_, PyModule>ListOrTupleenum to useBoundtypes and added#[derive(Clone)]ListOrTupleIteratorto returnBound<'py, PyAny>itemsPyTuple::new_bound->PyTuple::new,PyList::new_bound->PyList::newpy.get_type_bound->py.get_type?operatorFromPyObject: Migrated fromextracttoextract_boundmethodinto_py()andto_object()withinto_pyobject().unwrap().into()unsafe impl Syncfor bothConnectionandCursorstructs (required for PyO3 0.23+)#[pyo3(signature = ...)]attributes for functions with trailingOption<T>parameters:executeandexecutemany:#[pyo3(signature = (sql, parameters=None))]fetchmany:#[pyo3(signature = (size=None))]__exit__:#[pyo3(signature = (exc_type=None, _exc_val=None, _exc_tb=None))]&Bound<'_, PyModule>instead of&PyModule