Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
jorgecarleitao committed Aug 8, 2022
1 parent 4e45ccd commit 34c3539
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion examples/parquet_read_async.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ async fn main() -> Result<()> {
// the runtime.
// Furthermore, this operation is trivially paralellizable e.g. via rayon, as each iterator
// can be advanced in parallel (parallel decompression and deserialization).
let chunks = RowGroupDeserializer::new(column_chunks, row_group.num_rows() as usize, None);
let chunks = RowGroupDeserializer::new(column_chunks, row_group.num_rows(), None);
for maybe_chunk in chunks {
let chunk = maybe_chunk?;
println!("{}", chunk.len());
Expand Down
2 changes: 1 addition & 1 deletion examples/s3/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ async fn main() -> Result<()> {

// this is CPU-bounded and should be sent to a separate thread-pool.
// We do it here for simplicity
let chunks = read::RowGroupDeserializer::new(column_chunks, group.num_rows() as usize, None);
let chunks = read::RowGroupDeserializer::new(column_chunks, group.num_rows(), None);
let chunks = chunks.collect::<Result<Vec<_>>>()?;

// this is a single chunk because chunk_size is `None`
Expand Down
4 changes: 1 addition & 3 deletions src/io/parquet/read/row_group.rs
Original file line number Diff line number Diff line change
Expand Up @@ -260,8 +260,6 @@ pub async fn read_columns_many_async<
field_columns
.into_iter()
.zip(fields.into_iter())
.map(|(columns, field)| {
to_deserializer(columns, field, row_group.num_rows() as usize, chunk_size)
})
.map(|(columns, field)| to_deserializer(columns, field, row_group.num_rows(), chunk_size))
.collect()
}
2 changes: 1 addition & 1 deletion tests/it/io/parquet/read_indexes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ fn read_with_indexes(
vec![&c1.descriptor().descriptor.primitive_type],
schema.fields[1].clone(),
None,
row_group.num_rows() as usize,
row_group.num_rows(),
)?;

let arrays = arrays.collect::<Result<Vec<_>>>()?;
Expand Down
2 changes: 1 addition & 1 deletion tests/it/io/parquet/write_async.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ async fn test_parquet_async_roundtrip() {
let column_chunks = read_columns_many_async(factory, group, schema.fields.clone(), None)
.await
.unwrap();
let chunks = RowGroupDeserializer::new(column_chunks, group.num_rows() as usize, None);
let chunks = RowGroupDeserializer::new(column_chunks, group.num_rows(), None);
let mut chunks = chunks.collect::<Result<Vec<_>>>().unwrap();
out.append(&mut chunks);
}
Expand Down

0 comments on commit 34c3539

Please sign in to comment.