raulcd commented on code in PR #12800:
URL: https://github.com/apache/arrow/pull/12800#discussion_r848530602


##########
python/pyarrow/ipc.py:
##########
@@ -39,10 +39,17 @@ class RecordBatchStreamReader(lib._RecordBatchStreamReader):
     ----------
     source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object
         Either an in-memory buffer, or a readable file object.
+    options : pyarrow.ipc.IpcReadOptions
+        Options for IPC serialization.
+
+        If None, default values will be used.
+    memory_pool : MemoryPool, default None
+        Uses default memory pool if not specified.
     """
 
-    def __init__(self, source):
-        self._open(source)
+    def __init__(self, source, *, options=None, memory_pool=None):

Review Comment:
   This was the original implementation but based on the review comments from 
@jorisvandenbossche and @lidavidm in order to be consistent with other APIs in 
pyarrow we decided to expose it directly, the original comment is the following 
one:
   > But, more in general, almost all other APIs in pyarrow expose a direct 
memory_pool keyword, and not through an options class (eg also the CSV readers 
have a memory_pool keyword next to the different option classes). So it would 
also be an option here to expose memory_pool directly in 
RecordBatchStraem/FileReader/open_stream/open_file, and not through the 
IpcReadOptions class?
   
   and the thread were we discussed it:
   https://github.com/apache/arrow/pull/12800#discussion_r845144860



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to