From fbf19cc5b9d06ee5783431fa748d03592b22e45f Mon Sep 17 00:00:00 2001 From: Will Hopkins Date: Thu, 29 Oct 2026 22:58:58 -0400 Subject: [PATCH 1/2] docs(46927): document source param As described in issue 46927, the source param can take a file path. This commit documents that in the docstring. --- python/pyarrow/ipc.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/python/pyarrow/ipc.py b/python/pyarrow/ipc.py index 4e236678788a..676923d248d7 100644 --- a/python/pyarrow/ipc.py +++ b/python/pyarrow/ipc.py @@ -38,7 +38,7 @@ class RecordBatchStreamReader(lib._RecordBatchStreamReader): Parameters ---------- source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object - Either an in-memory buffer, or a readable file object. + Either an in-memory buffer, file path, or a readable file object. If you want to use memory map use MemoryMappedFile as source. options : pyarrow.ipc.IpcReadOptions Options for IPC deserialization. @@ -97,7 +97,7 @@ class RecordBatchFileReader(lib._RecordBatchFileReader): Parameters ---------- source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object - Either an in-memory buffer, or a readable file object. + Either an in-memory buffer, file path, or a readable file object. If you want to use memory map use MemoryMappedFile as source. footer_offset : int, default None If the file is embedded in some larger file, this is the byte offset to @@ -172,7 +172,7 @@ def open_stream(source, *, options=None, memory_pool=None): Parameters ---------- source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object - Either an in-memory buffer, or a readable file object. + Either an in-memory buffer, file path, or a readable file object. options : pyarrow.ipc.IpcReadOptions Options for IPC serialization. If None, default values will be used. @@ -211,7 +211,7 @@ def open_file(source, footer_offset=None, *, options=None, memory_pool=None): Parameters ---------- source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object - Either an in-memory buffer, or a readable file object. + Either an in-memory buffer, file path, or a readable file object. footer_offset : int, default None If the file is embedded in some larger file, this is the byte offset to the very end of the file data. From f68538586089c74f82f66af6fef69b6c2518cd95 Mon Sep 17 00:00:00 2001 From: Will Hopkins Date: Fri, 30 Oct 2026 08:42:40 -0400 Subject: [PATCH 2/2] docs: switch to any of --- python/pyarrow/ipc.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/python/pyarrow/ipc.py b/python/pyarrow/ipc.py index 676923d248d7..062bbc2cd2ea 100644 --- a/python/pyarrow/ipc.py +++ b/python/pyarrow/ipc.py @@ -38,7 +38,7 @@ class RecordBatchStreamReader(lib._RecordBatchStreamReader): Parameters ---------- source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object - Either an in-memory buffer, file path, or a readable file object. + Any of an in-memory buffer, file path, or a readable file object. If you want to use memory map use MemoryMappedFile as source. options : pyarrow.ipc.IpcReadOptions Options for IPC deserialization. @@ -97,7 +97,7 @@ class RecordBatchFileReader(lib._RecordBatchFileReader): Parameters ---------- source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object - Either an in-memory buffer, file path, or a readable file object. + Any of an in-memory buffer, file path, or a readable file object. If you want to use memory map use MemoryMappedFile as source. footer_offset : int, default None If the file is embedded in some larger file, this is the byte offset to @@ -172,7 +172,7 @@ def open_stream(source, *, options=None, memory_pool=None): Parameters ---------- source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object - Either an in-memory buffer, file path, or a readable file object. + Any of an in-memory buffer, file path, or a readable file object. options : pyarrow.ipc.IpcReadOptions Options for IPC serialization. If None, default values will be used. @@ -211,7 +211,7 @@ def open_file(source, footer_offset=None, *, options=None, memory_pool=None): Parameters ---------- source : bytes/buffer-like, pyarrow.NativeFile, or file-like Python object - Either an in-memory buffer, file path, or a readable file object. + Any of an in-memory buffer, file path, or a readable file object. footer_offset : int, default None If the file is embedded in some larger file, this is the byte offset to the very end of the file data.