Skip to content

Panic quick-round-tripping parquet file #15571

@NotTheDr01ds

Description

@NotTheDr01ds

Describe the bug

polars save panics while attempting to open and save a parquet file in the same pipeline.

How to reproduce

[ 1 2 3 ] | polars into-df | polars save simple.parquet
polars open simple.parquet | polars save simple.parquet
# => thread 'polars-0' panicked at /home/ntd/.local/share/rust/cargo/registry/src/index.crates.io-6f17d22bba15001f/polars-io-# => 0.46.0/src/parquet/read/mmap.rs:49:23:
# => range end index 106 out of range for slice of length 0
# => note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
# => Rayon: detected unexpected panic; aborting
# => thread 'plugin runner (primary)' panicked at /home/ntd/.local/share/rust/cargo/registry/src/index.crates.io-6f17d22bba15001f/polars-io-0.46.0/src/pl_async.rs:362:22:
# => called `Result::unwrap()` on an `Err` value: RecvError(())
# => Error:   × Failed to receive response to plugin call from `polars`
# =>    ╭─[entry #13:1:30]
# =>  1 │ polars open simple.parquet | polars save simple.parquet
# =>    ·                              ─────┬─────
# =>    ·                                   ╰── while waiting for this operation to complete
# =>    ╰────
# =>   help: try restarting the plugin with `plugin use 'polars'`

Expected behavior

This might be expected to fail given the way polars works (I'm not sure), but it probably shouldn't panic.

Configuration

key value
version 0.103.1
major 0
minor 103
patch 1
branch main
commit_hash c8c0184
build_os linux-x86_64
build_target x86_64-unknown-linux-gnu
rust_version rustc 1.84.1 (e71f9a9a9 2025-01-27)
rust_channel 1.84.1-x86_64-unknown-linux-gnu
cargo_version cargo 1.84.1 (66221abde 2024-11-19)
build_time 2025-04-11 14:54:23 -04:00
build_rust_channel release
allocator standard
features default, sqlite, trash
installed_plugins formats 0.101.0, gstat 0.101.1, polars 0.102.1, query 0.102.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    A:plugin-polarsWork related to the polars dataframe implementationcategory:bugSomething isn't workingpanic

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions