Skip to content

fix: [branch-1.2] match Spark nullness for missing nested Parquet fields (#7085) - #7313

Merged
andygrove merged 1 commit into
apache:branch-1.2from
andygrove:backport-7085-branch-1.2
Oct 29, 2026
Merged

andygrove merged 1 commit into
apache:branch-1.2from
andygrove:backport-7085-branch-1.2

Conversation

@andygrove

Copy link
Copy Markdown
Member

Which issue does this PR close?

Backport of #7085 to branch-1.2. #7085 closes #7030 on main.

Rationale for this change

When every requested nested leaf is missing from a Parquet file, the native scan can return non-null containers where Spark returns NULL. That changes IS NULL, filters and count results, silently, on the default configuration (#7030, priority:critical, correctness). branch-1.2 has the bug, so it needs the fix before 1.2.0 ships. #7085 also makes native scans of name-mapped nested Iceberg tables fall back to Spark.

branch-1.2 is the newest release branch, so no newer branch needs a backport. #7085 carries no backport-1.1 label, so no branch-1.1 backport is part of this.

What changes are included in this PR?

git cherry-pick -x c4a0b1f2bc of the squash commit of #7085, with no adaptations. It applied without conflicts. The only change outside tests, docs and the scan code is a comment in operator.proto; no proto field is added or renumbered. See #7085 for the full description.

How are these changes tested?

On this branch, with a libcomet built from the pick:

  • cargo check --all-targets, cargo fmt --check, and the 351 parquet unit tests in datafusion-comet pass.
  • ./mvnw test-compile passes.
  • CometNativeReaderSuite, IcebergReflectionSuite and CometIcebergNativeSuite pass: 255 succeeded, 0 failed, 3 canceled. The canceled tests are version-conditional (issue #4136, an unknown partition transform, and an output-ordering fallback); the new tests all ran.
  • With parquet_support.rs reverted to branch-1.2, issue #7030: missing nested fields - legacy true in CometNativeReaderSuite fails, so the branch has the bug and the test catches it.

I did not run the Spark SQL test suites or the Iceberg suites across versions that #7085 ran in CI.

…lds (apache#7085)

* fix: match Spark nullness for missing nested Parquet fields

* fix: fall back for name-mapped nested Iceberg scans

* fix: decline Iceberg scans when table properties cannot be read

* docs: migrate nested-field notes to consolidated scan guides

* docs: describe list and map nulling for all-missing nested leaves

(cherry picked from commit c4a0b1f)
@andygrove andygrove added bug Something isn't working area:scan Parquet scan / data reading area:Iceberg labels Oct 29, 2026
@andygrove
andygrove merged commit 835a616 into apache:branch-1.2 Oct 29, 2026
206 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:Iceberg area:scan Parquet scan / data reading bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants