Skip to content

Commit

Permalink
[WIP] Work around arrow-rs bug
Browse files Browse the repository at this point in the history
  • Loading branch information
hohav committed Sep 8, 2024
1 parent ab95c3e commit 53cd5f8
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion src/io/peppi/de.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,18 @@ pub struct Opts {

fn read_arrow_frames<R: Read>(mut r: R, version: slippi::Version) -> Result<Frame> {
// magic number `ARROW1\0\0`
expect_bytes(&mut r, &[65, 82, 82, 79, 87, 49, 0, 0])?;
//expect_bytes(&mut r, &[65, 82, 82, 79, 87, 49, 0, 0])?;
// temp hack to work around https://github.com/apache/arrow-rs/issues/6311
expect_bytes(&mut r, &[
65, 82, 82, 79, 87, 49, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0,
])?;
let mut reader = StreamReader::try_new(r, None)?;
let batch = reader.next().ok_or(err!("no batches"))??;
let frames = StructArray::from(batch);
Expand Down

0 comments on commit 53cd5f8

Please sign in to comment.