You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Introduce the listagg field aggregator for pypaimon.
This change adds support for the listagg aggregation function in the Python reader, aligning its behavior with the Java implementation. It supports configurable delimiters through fields.<field-name>.list-agg-delimiter and optional deduplication via ields.<field-name>.distinct.
`When configuring an empty delimiter in listagg distinguish, it will directly throw 'ValueError: empty separator'. An empty string is a valid configuration, and all 14 tests have passed, but it does not cover this boundary; The minimum use case has been stably reproduced.
`When configuring an empty delimiter in listagg distinguish, it will directly throw 'ValueError: empty separator'. An empty string is a valid configuration, and all 14 tests have passed, but it does not cover this boundary; The minimum use case has been stably reproduced.
Thanks for catching this. Python's str.split("") raises ValueError, while an empty delimiter is a valid configuration. I've updated the implementation to handle this case consistently with the Java behavior and added a test to cover this boundary.
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
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.
Purpose
Introduce the listagg field aggregator for pypaimon.
This change adds support for the listagg aggregation function in the Python reader, aligning its behavior with the Java implementation. It supports configurable delimiters through
fields.<field-name>.list-agg-delimiterand optional deduplication viaields.<field-name>.distinct.Tests
python -m pytest pypaimon/tests/test_field_aggregators.py::FieldListaggAggTest -qgit diff --check