โ FAQ
-
What versions of Polars are supported?
Short answer: Polars >= 1.37.0 is required.
Long answer: polars-bio requires Polars 1.37.1 or later because it uses the
ArrowStreamExportablefeature (PR #25994) for efficient zero-copy data exchange between Polars LazyFrames and the Rust-based genomic operations engine. This feature provides:- Arrow C Stream FFI: LazyFrames export data via
__arrow_c_stream__(), enabling direct Arrow FFI transfer to Rust without Python object conversions - GIL-free streaming: The GIL is only acquired once when exporting the stream; all subsequent batch processing happens in pure Rust
- Reduced memory overhead: No Python iterator objects or intermediate conversions
We recommend handling most of the heavy lifting on the DataFusion side (e.g., using SQL and views) and relying on Polars' streaming capabilities primarily for projection, filtering, and sinking results. See the Polars Integration section for more details on the architecture.
- Arrow C Stream FFI: LazyFrames export data via
-
What to do if I get
Illegal instruction (core dumped)when using polars-bio? This error is likely due to the fact that the ABI of the polars-bio wheel package does not match the ABI of the Python interpreter. To fix this, you can build the wheel package from source. See Quickstart for more information. -
How to build the documentation? To build the documentation, you need to install the
Some pages of the documentation take a while to buildโto speed up the process, you can disable dynamic content rendering:polars-biopackage and then run the following command in the root directory of the repository: -
How to build the source code and install in the current virtual environment?
-
How to run the integration tests? To run the integration tests, you need to have the
azure-cli,docker, andpytestinstalled. Then, you can run the following commands:Check thecd it source bin/start.sh JUPYTER_PLATFORM_DIRS=1 pytest it_object_storage_io.py -o log_cli=true --log-cli-level=INFO source bin/stop.shREADMEinitdirectory for more information.