-
Notifications
You must be signed in to change notification settings - Fork 73
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
support memoryviews even on bytearray? #78
Comments
I ran into this too, see #65 |
Thanks for the research, check #80 for a potential solution. |
@ThomasWaldmann #80 was merged to master I'd really appreciate if you could check it out. |
There is now also #94 for decompressing from a memoryview or bytearray. |
@ThomasWaldmann Could you check if the newest release fixes this issue? |
ping! I'll close this under the vague assumption that it has been fixed. Feel free to open a new ticket if this is a mistake. |
Seems like attic (which is py3 only) would want to give a memoryview on a bytearray (called data) to blosc's compress, but it doesn't get accepted there, so I would have to use bytes(data) to first convert to an acceptable type - and this would make a full new copy of it, right?
I tried to losen the first type check in blosc to accept memoryviews also, but then it just fails a little later with:
Seems like code like that (see HAS_NEW_BUFFER) might be useful (but please check, I am not familiar with low-level stuff):
https://github.com/dlitz/pycrypto/pull/81/files#diff-d29a5dec14d8ca1fc5d169320636fc52R631
The text was updated successfully, but these errors were encountered: