Skip to content
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

DEP: Deprecate 4 ndarray.ctypes methods #19031

Merged
merged 7 commits into from May 18, 2021
Merged

DEP: Deprecate 4 ndarray.ctypes methods #19031

merged 7 commits into from May 18, 2021

Conversation

BvB93
Copy link
Member

@BvB93 BvB93 commented May 18, 2021

Xref #19029 (comment).

Four methods of the ndarray.ctypes object have been deprecated, as they are (undocumentated) implementation artifacts of their respective property. They were originally kept around for the sake of backwards compatibility (79baef7), but as this was three years ago it should be safe to formally deprecate them by now.

# kept for compatibility
get_data = data.fget
get_shape = shape.fget
get_strides = strides.fget
get_as_parameter = _as_parameter_.fget

numpy/core/_internal.py Outdated Show resolved Hide resolved
Co-Authored-By: Sebastian Berg <sebastian@sipsolutions.net>
Co-Authored-By: Eric Wieser <425260+eric-wieser@users.noreply.github.com>
Bas van Beek and others added 2 commits May 18, 2021 20:55
Co-Authored-By: Eric Wieser <425260+eric-wieser@users.noreply.github.com>
Copy link
Member

@eric-wieser eric-wieser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me. I would have deprecated them at the time, but the bugfix had already turned into a refactor and I didn't want to throw in a deprecation in the same PR.

@seberg
Copy link
Member

seberg commented May 18, 2021

Thanks! That one travis run has beeing making problems. I am going to put it in, since I don't expect complains on the mailing list. If they come, happy to revert :).

@seberg seberg merged commit 39110f3 into numpy:main May 18, 2021
@BvB93 BvB93 deleted the iternal_dep branch May 18, 2021 20:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants