Repository navigation
Conversation
…on object implementing the buffer/memoryview protocol
wesm
reviewed
Mar 15, 2017
| if view.ndim != 1 or view.itemsize != 1: | ||
| raise ValueError('Value must be one-dimensional and byte-sized to convert to Buffer: {0}' | ||
| .format(type(obj))) | ||
| buf.reset(new pyarrow.PyBytesBuffer(view.obj)) |
Member
There was a problem hiding this comment.
I think that view.obj is the base object here https://github.com/python/cpython/blob/6f0eb93183519024cb360162bdd81b9faec97ba6/Objects/memoryobject.c#L43 -- can you try using something other than a bytes object in your test case?
Member
|
I'm 90% certain this patch is going to require changes in pyarrow/io.h/cc to be based on the buffer protocol instead of PyBytes |
Contributor
Author
|
@wesm You're right, I read the memoryview docs backwards. It will definitely require a change in pyarrow/io.[cc|h]. I'm going to close this pull request as the proper change requires a good deal more work. |
wesm
added a commit
to wesm/arrow
that referenced
this pull request
Sep 8, 2018
This will enable most of the outstanding PRs to be rebased and then merged Close apache#384 Close apache#394 Author: Wes McKinney <wes.mckinney@twosigma.com> Closes apache#397 from wesm/PARQUET-1104 and squashes the following commits: 4106c5b [Wes McKinney] Include boost_system in static toolchain until ARROW-1536 resolved 005ee74 [Wes McKinney] Account for internal API change in ARROW-1511 3cab00d [Wes McKinney] Change MutableBuffer to Buffer to account for deprecation in ARROW-1402 7cd9702 [Wes McKinney] Upgrade to Apache Arrow 0.7.0 RC0 Change-Id: I6d0af9910da4d123ac66ec1a58a0de96c7ecaa95
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.
No description provided.