[Data] Prevent Limit from getting pushed past map_groups#60881
Merged
bveeramani merged 2 commits intomasterfrom Feb 9, 2026
Merged
[Data] Prevent Limit from getting pushed past map_groups#60881bveeramani merged 2 commits intomasterfrom
Limit from getting pushed past map_groups#60881bveeramani merged 2 commits intomasterfrom
Conversation
Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu>
Contributor
There was a problem hiding this comment.
Code Review
This pull request correctly fixes a bug in map_groups where an incorrect optimization could be applied. By setting udf_modifying_row_count=True, it acknowledges that the user-defined function in map_groups can change the number of rows. This prevents the Limit operator from being incorrectly pushed down, ensuring correct behavior. The change is simple, targeted, and correct.
iamjustinhsu
approved these changes
Feb 9, 2026
Contributor
|
do we have existing test for this? |
Member
Author
Ah, good catch. Forgot to push my change with the test |
Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu>
bveeramani
added a commit
that referenced
this pull request
Feb 9, 2026
This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes #60872). For more context, see: * #60448 * #60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu>
preneond
pushed a commit
to preneond/ray
that referenced
this pull request
Feb 15, 2026
…ject#60881) This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes ray-project#60872). For more context, see: * ray-project#60448 * ray-project#60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu> Signed-off-by: Ondrej Prenek <ondra.prenek@gmail.com>
limarkdcunha
pushed a commit
to limarkdcunha/ray
that referenced
this pull request
Feb 17, 2026
…ject#60881) This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes ray-project#60872). For more context, see: * ray-project#60448 * ray-project#60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu>
MuhammadSaif700
pushed a commit
to MuhammadSaif700/ray
that referenced
this pull request
Feb 17, 2026
…ject#60881) This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes ray-project#60872). For more context, see: * ray-project#60448 * ray-project#60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu> Signed-off-by: Muhammad Saif <2024BBIT200@student.Uet.edu.pk>
Kunchd
pushed a commit
to Kunchd/ray
that referenced
this pull request
Feb 17, 2026
…ject#60881) This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes ray-project#60872). For more context, see: * ray-project#60448 * ray-project#60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu>
ans9868
pushed a commit
to ans9868/ray
that referenced
this pull request
Feb 18, 2026
…ject#60881) This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes ray-project#60872). For more context, see: * ray-project#60448 * ray-project#60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu> Signed-off-by: Adel Nour <ans9868@nyu.edu>
Aydin-ab
pushed a commit
to kunling-anyscale/ray
that referenced
this pull request
Feb 20, 2026
…ject#60881) This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes ray-project#60872). For more context, see: * ray-project#60448 * ray-project#60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu>
peterxcli
pushed a commit
to peterxcli/ray
that referenced
this pull request
Feb 25, 2026
…ject#60881) This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes ray-project#60872). For more context, see: * ray-project#60448 * ray-project#60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu> Signed-off-by: peterxcli <peterxcli@gmail.com>
peterxcli
pushed a commit
to peterxcli/ray
that referenced
this pull request
Feb 25, 2026
…ject#60881) This PR updates `map_groups` to assume that the UDF might change the row count. This change is necessary to fix a bug where `Limit` gets incorrectly pushed past the `map_groups` (fixes ray-project#60872). For more context, see: * ray-project#60448 * ray-project#60756 --------- Signed-off-by: Balaji Veeramani <bveeramani@berkeley.edu> Signed-off-by: peterxcli <peterxcli@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR updates
map_groupsto assume that the UDF might change the row count. This change is necessary to fix a bug whereLimitgets incorrectly pushed past themap_groups(fixes #60872).For more context, see:
map_batchesby default #60448MapBatcheseven if they modify the row count #60756