You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@arrow.apache.org by "Antoine Pitrou (Jira)" <ji...@apache.org> on 2019/09/04 10:07:00 UTC
[jira] [Resolved] (ARROW-4836) [Python] "Cannot tell() a compressed
stream" when using RecordBatchStreamWriter
[ https://issues.apache.org/jira/browse/ARROW-4836?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Antoine Pitrou resolved ARROW-4836.
-----------------------------------
Resolution: Fixed
Issue resolved by pull request 5262
[https://github.com/apache/arrow/pull/5262]
> [Python] "Cannot tell() a compressed stream" when using RecordBatchStreamWriter
> -------------------------------------------------------------------------------
>
> Key: ARROW-4836
> URL: https://issues.apache.org/jira/browse/ARROW-4836
> Project: Apache Arrow
> Issue Type: Bug
> Components: Python
> Affects Versions: 0.12.1
> Reporter: Mike Pedersen
> Assignee: Antoine Pitrou
> Priority: Major
> Labels: pull-request-available
> Fix For: 0.15.0
>
> Time Spent: 0.5h
> Remaining Estimate: 0h
>
> It does not seem like RecordBatchStreamWriter works with compressed streams:
> {code:python}
> >>> import pyarrow as pa
> >>> pa.__version__
> '0.12.1'
> >>> stream = pa.output_stream('/tmp/a.gz')
> >>> batch = pa.RecordBatch.from_arrays([pa.array([1])], ['a'])
> >>> writer = pa.RecordBatchStreamWriter(stream, batch.schema)
> >>> writer.write(batch)
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> File "pyarrow/ipc.pxi", line 181, in pyarrow.lib._RecordBatchWriter.write
> File "pyarrow/ipc.pxi", line 196, in pyarrow.lib._RecordBatchWriter.write_batch
> File "pyarrow/error.pxi", line 89, in pyarrow.lib.check_status
> pyarrow.lib.ArrowNotImplementedError: Cannot tell() a compressed stream
> {code}
> As I understand the documentation, this should be possible, right?
--
This message was sent by Atlassian Jira
(v8.3.2#803003)