Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

POLARS_NEW_MULTIFILE bug when selecting hive column #20853

Open
2 tasks done
kszlim opened this issue Jan 22, 2025 · 0 comments
Open
2 tasks done

POLARS_NEW_MULTIFILE bug when selecting hive column #20853

kszlim opened this issue Jan 22, 2025 · 0 comments
Labels
bug Something isn't working needs triage Awaiting prioritization by a maintainer python Related to Python Polars

Comments

@kszlim
Copy link
Contributor

kszlim commented Jan 22, 2025

Checks

  • I have checked that this issue has not already been reported.
  • I have confirmed this bug exists on the latest version of Polars.

Reproducible example

import polars as pl
import os

df = pl.DataFrame({"id": [1,1,1,2,2,2], "c": [1, 2, 3, 1, 2, 3]})
df.write_parquet("dataset", partition_by="id")

os.environ["POLARS_NEW_MULTIFILE"] = "1"

print(pl.scan_parquet("dataset", hive_partitioning=True).select(pl.col("id").unique()).collect())

Log output

polars.exceptions.ColumnNotFoundError: "id" not found

Issue description

This should correctly return

Expected behavior

┌─────┐
│ id  │
│ --- │
│ i64 │
╞═════╡
│ 1   │
│ 2   │
└─────┘

Installed versions

--------Version info---------
Polars:              1.20.0
Index type:          UInt32
Platform:            macOS-15.1-arm64-arm-64bit
Python:              3.12.7 (main, Oct 16 2024, 07:12:08) [Clang 18.1.8 ]
LTS CPU:             False

----Optional dependencies----
Azure CLI            <not installed>
adbc_driver_manager  <not installed>
altair               <not installed>
azure.identity       <not installed>
boto3                <not installed>
cloudpickle          <not installed>
connectorx           <not installed>
deltalake            <not installed>
fastexcel            <not installed>
fsspec               <not installed>
gevent               <not installed>
google.auth          <not installed>
great_tables         <not installed>
matplotlib           <not installed>
nest_asyncio         <not installed>
numpy                <not installed>
openpyxl             <not installed>
pandas               <not installed>
pyarrow              <not installed>
pydantic             <not installed>
pyiceberg            <not installed>
sqlalchemy           <not installed>
torch                <not installed>
xlsx2csv             <not installed>
xlsxwriter           <not installed>
@kszlim kszlim added bug Something isn't working needs triage Awaiting prioritization by a maintainer python Related to Python Polars labels Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs triage Awaiting prioritization by a maintainer python Related to Python Polars
Projects
None yet
Development

No branches or pull requests

1 participant