Skip to content

Fix topk emitted batches - #24481

Open
cetra3 wants to merge 2 commits into
apache:mainfrom
pydantic:fix_topk_emitted_batches
Open

Fix topk emitted batches#24481
cetra3 wants to merge 2 commits into
apache:mainfrom
pydantic:fix_topk_emitted_batches

Conversation

@cetra3

@cetra3 cetra3 commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

Which issue does this PR close?

Rationale for this change

Fixes some issues around metrics and TopK execution nodes

What changes are included in this PR?

Adjusts to include metrics in PartitionedTopKExec and also fixes the batch count in TopK

Are these changes tested?

Yes new tests added.

Are there any user-facing changes?

No new traits, etc.. just fixes some bugs on the physical plan side

@github-actions github-actions Bot added core Core DataFusion crate physical-plan Changes to the physical-plan crate labels Aug 19, 2026
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 87.17949% with 10 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.24%. Comparing base (c429919) to head (e88598c).

Files with missing lines Patch % Lines
datafusion/physical-plan/src/topk/mod.rs 86.66% 5 Missing and 5 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #24481      +/-   ##
==========================================
- Coverage   81.24%   81.24%   -0.01%     
==========================================
  Files        1113     1113              
  Lines      392744   392816      +72     
  Branches   392744   392816      +72     
==========================================
+ Hits       319090   319145      +55     
- Misses      54900    54909       +9     
- Partials    18754    18762       +8     

☔ View full report in Codecov by Harness.
📢 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.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core Core DataFusion crate physical-plan Changes to the physical-plan crate

Projects

None yet

2 participants