-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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 service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GH-45129: [Python][C++] Fix usage of deprecated C++ functionality on pyarrow #45189
base: main
Are you sure you want to change the base?
Conversation
|
@github-actions crossbow submit -g python |
Revision: c1deb19 Submitted crossbow builds: ursacomputing/crossbow @ actions-d40040ac1a |
The cython2 failure is related:
the following patch would work but I don't think this should be the fix, as I am pretty sure diff --git a/python/pyarrow/src/arrow/python/common.h b/python/pyarrow/src/arrow/python/common.h
index 4a7886695e..30acf0d6ed 100644
--- a/python/pyarrow/src/arrow/python/common.h
+++ b/python/pyarrow/src/arrow/python/common.h
@@ -260,7 +260,7 @@ class SmartPtrNoGIL : public SmartPtr<Ts...> {
template <typename V>
SmartPtrNoGIL& operator=(V&& v) {
auto release_guard = optional_gil_release();
- Base::operator=(std::forward<V>(v));
+ Base::operator=(std::move(v));
return *this;
} |
@github-actions crossbow submit test-conda-python-3.10-cython2 |
Revision: 07f7acd Submitted crossbow builds: ursacomputing/crossbow @ actions-3db166d478
|
@github-actions crossbow submit -g python |
This comment was marked as outdated.
This comment was marked as outdated.
@github-actions crossbow submit -g python |
Revision: babbe9f Submitted crossbow builds: ursacomputing/crossbow @ actions-f876b9ef9d |
@github-actions crossbow submit test-conda-python-3.10-cython2 |
Revision: f292cc1 Submitted crossbow builds: ursacomputing/crossbow @ actions-58dca82b3c
|
Ok, so the shared_ptr version works but not the unique_ptr one? In this case, we can keep using the shared_ptr approach. |
By the way, why do we want to support Cython 2? @jorisvandenbossche |
I would say we can drop the cython 2 support. |
I created an issue to track that as it is not the first time we say the same. I'll do and then I'll rebase this one. I'll ping to merge once CI is green again. |
…mentation of SmartPtrNoGIL operator
@github-actions crossbow submit -g python |
Revision: 0a1d214 Submitted crossbow builds: ursacomputing/crossbow @ actions-74244302df |
CI failures are unrelated, they are failing on main and I've opened individual issues to track them. @pitrou I've rebased after the required cython bump. This should be ready to review/merge now that there's no CI failure. |
Rationale for this change
We are using two C++ deprecated APIs:
What changes are included in this PR?
Update code to use non deprecated functions.
Are these changes tested?
Yes via CI with existing tests.
Are there any user-facing changes?
No