Skip to content

fix: Bucketed scan fallback for native_datafusion Parquet scan #1720

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

Merged
merged 3 commits into from
May 8, 2025

Conversation

mbutrovich
Copy link
Contributor

Which issue does this PR close?

Closes #.

Rationale for this change

See #1719

What changes are included in this PR?

Fallback for bucketed scan when using native_datafusion.

How are these changes tested?

Existing Spark SQL tests.

Copy link
Contributor

@parthchandra parthchandra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While this is ok to pass tests what we need is for CometNativeScanExec to implement support for bucketing like here https://github.com/apache/spark/blob/bc013c031b6b3e0c34cab6f9dc2ba6b85f5edab9/sql/core/src/main/scala/org/apache/spark/sql/execution/DataSourceScanExec.scala#L722

Copy link
Member

@andygrove andygrove left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @mbutrovich

@parthchandra
Copy link
Contributor

While this is ok to pass tests what we need is for CometNativeScanExec to implement support for bucketing like here https://github.com/apache/spark/blob/bc013c031b6b3e0c34cab6f9dc2ba6b85f5edab9/sql/core/src/main/scala/org/apache/spark/sql/execution/DataSourceScanExec.scala#L722

You already said so in #1719. :)

@codecov-commenter
Copy link

codecov-commenter commented May 7, 2025

Codecov Report

Attention: Patch coverage is 44.44444% with 5 lines in your changes missing coverage. Please review.

Project coverage is 58.63%. Comparing base (f09f8af) to head (564b5fa).
Report is 181 commits behind head on main.

Files with missing lines Patch % Lines
...n/scala/org/apache/comet/rules/CometScanRule.scala 44.44% 4 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #1720      +/-   ##
============================================
+ Coverage     56.12%   58.63%   +2.50%     
- Complexity      976     1143     +167     
============================================
  Files           119      129      +10     
  Lines         11743    12644     +901     
  Branches       2251     2364     +113     
============================================
+ Hits           6591     7414     +823     
- Misses         4012     4052      +40     
- Partials       1140     1178      +38     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mbutrovich
Copy link
Contributor Author

mbutrovich commented May 8, 2025

Interestingly, we were passing the Comet test of bucketed scan before:

https://github.com/apache/datafusion-comet/actions/runs/14893567863/job/41846178932?pr=1720#step:6:3558

I suspect the issue shows up when buckets are pruned at planning time, which this test might not exercise.

@andygrove andygrove merged commit b36db64 into apache:main May 8, 2025
78 checks passed
@mbutrovich mbutrovich deleted the bucketed_fallback branch May 15, 2025 19:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants