-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Allow converting an image to a numpy array to raise errors #5379
Conversation
Thanks for chasing up. Let's open an issue at NumPy as well? https://gitter.im/numpy/numpy?at=6067b4ef3153ce63a3b6dcad says:
Maybe they won't have it deprecated and fixed by the next Pillow release in 3 months but let's at least give them a chance, and review this before release. I've added it to the 8.3.0 milestone. |
Ok, raised at numpy/numpy#18723 |
NumPy 1.21 will deprecate the error catching, raising a warning in this situation. It is expected that NumPy 1.23, a year later, would start to raise an error. |
Thanks for following up! |
numpy/numpy#20835 has been merged into NumPy, so NumPy 1.23.should raise an error. |
NumPy 1.23 has been released, so I've created #6394 to revert this. |
Resolves #5084
The following code runs without raising an error.
Even though an OSError is raised if
__array_interface__
is accessed directly.This is a bug in numpy.
This PR works around that bug by replacing
__array_interface__
with__array__
.