From 0ff15976733c0b1b88740161b19fc9d8a03c835f Mon Sep 17 00:00:00 2001 From: AuroraVoyage Date: Thu, 16 Jul 2026 14:34:59 +0800 Subject: [PATCH 1/2] [python] Update aggregation unsupported message. --- paimon-python/pypaimon/read/merge_engine_support.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/paimon-python/pypaimon/read/merge_engine_support.py b/paimon-python/pypaimon/read/merge_engine_support.py index 998dd72e8032..7cd948788569 100644 --- a/paimon-python/pypaimon/read/merge_engine_support.py +++ b/paimon-python/pypaimon/read/merge_engine_support.py @@ -235,8 +235,8 @@ def check_supported(table) -> None: "built-in aggregators ({}); retract opt-ins " "(aggregation.remove-record-on-delete, " "fields..ignore-retract) " - "and other aggregators (product / listagg / collect / " - "merge_map* / nested_update* / theta_sketch / " + "and other aggregators (product / collect / " + "merge_map* / theta_sketch / " "hll_sketch / roaring_bitmap_*) are not yet supported. " "Open an issue to track support.".format( ", ".join(sorted(unsupported)), @@ -287,8 +287,7 @@ def aggregation_unsupported_options(table) -> Set[str]: ``builtin_seq_comparator``). 3. Out-of-scope aggregator selections: ``fields..aggregate- function`` and ``fields.default-aggregate-function`` set to an - identifier this engine doesn't support yet (e.g. ``collect``, - ``nested_update``). + identifier this engine doesn't support yet (e.g. ``collect``). """ flagged: Set[str] = set() raw = table.options.options.to_map() From f6e780243aed5362aacccd196fed1ed73071fd3c Mon Sep 17 00:00:00 2001 From: AuroraVoyage Date: Sat, 25 Jul 2026 21:24:26 +0800 Subject: [PATCH 2/2] [python] Keep aggregation validation message in sync. Update the unsupported-aggregator validation message to reflect the currently supported aggregators. Remove product, listagg, collect, nested_update*, and nested_partial_update from the unsupported-aggregator message. --- paimon-python/pypaimon/read/merge_engine_support.py | 7 +++---- .../pypaimon/read/reader/aggregate/aggregators.py | 9 +++++---- .../pypaimon/read/reader/aggregation_merge_function.py | 7 +++---- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/paimon-python/pypaimon/read/merge_engine_support.py b/paimon-python/pypaimon/read/merge_engine_support.py index fbe5406a5459..2dd0b5b6bc81 100644 --- a/paimon-python/pypaimon/read/merge_engine_support.py +++ b/paimon-python/pypaimon/read/merge_engine_support.py @@ -212,9 +212,8 @@ def check_supported(table) -> None: "built-in aggregators ({}); retract opt-ins " "(aggregation.remove-record-on-delete, " "fields..ignore-retract) " - "and other aggregators (product / listagg / collect / " - "nested_update* / theta_sketch / " - "hll_sketch / roaring_bitmap_*) are not yet supported. " + "and other aggregators (hll_sketch / roaring_bitmap_*) " + "are not yet supported. " "Open an issue to track support.".format( ", ".join(sorted(unsupported)), ", ".join(sorted(_AGGREGATION_SUPPORTED_AGG_FUNCS)), @@ -264,7 +263,7 @@ def aggregation_unsupported_options(table) -> Set[str]: ``builtin_seq_comparator``). 3. Out-of-scope aggregator selections: ``fields..aggregate- function`` and ``fields.default-aggregate-function`` set to an - identifier this engine doesn't support yet (e.g. ``collect``). + identifier this engine doesn't support yet (e.g. ``hll_sketch``). """ flagged: Set[str] = set() raw = table.options.options.to_map() diff --git a/paimon-python/pypaimon/read/reader/aggregate/aggregators.py b/paimon-python/pypaimon/read/reader/aggregate/aggregators.py index 5c325d99ebc7..9710d862533c 100644 --- a/paimon-python/pypaimon/read/reader/aggregate/aggregators.py +++ b/paimon-python/pypaimon/read/reader/aggregate/aggregators.py @@ -22,12 +22,13 @@ via :func:`register_aggregator`, so importing ``pypaimon.read.reader.aggregate`` makes all of them discoverable. -This module ships 10 aggregators — the primary-key placeholder plus -the 9 most commonly-used value aggregators: ``primary_key`` / +This module ships 18 aggregators — the primary-key placeholder plus +the 17 most commonly-used value aggregators: ``primary_key`` / ``last_value`` / ``last_non_null_value`` / ``first_value`` / ``first_non_null_value`` / ``sum`` / ``max`` / ``min`` / ``bool_or`` -/ ``bool_and``. Other aggregators (``product`` / ``listagg`` / -``collect`` / ``merge_map`` / ``nested_update`` / ``theta_sketch`` / +/ ``bool_and`` / ``product`` / ``listagg`` / ``collect`` / +``merge_map`` / ``merge_map_with_keytime`` / ``nested_update`` / +``nested_partial_update`` / ``theta_sketch``. Other aggregators ( ``hll_sketch`` / ``roaring_bitmap_*``) are intentionally deferred — the registry will report them as unsupported so users see a clear error rather than a silent fallback. diff --git a/paimon-python/pypaimon/read/reader/aggregation_merge_function.py b/paimon-python/pypaimon/read/reader/aggregation_merge_function.py index ae666734032a..704a6527feb0 100644 --- a/paimon-python/pypaimon/read/reader/aggregation_merge_function.py +++ b/paimon-python/pypaimon/read/reader/aggregation_merge_function.py @@ -27,10 +27,9 @@ This is the **core merge semantics only**. Retract on DELETE / UPDATE_BEFORE rows (with ``aggregation.remove-record-on-delete`` and -``fields..ignore-retract`` opt-ins) and ~14 additional -aggregators (``product`` / ``listagg`` / ``collect`` / ``merge_map`` / -``nested_update`` / ``theta_sketch`` / ``hll_sketch`` / -``roaring_bitmap_*``) are intentionally deferred. Non-INSERT row +``fields..ignore-retract`` opt-ins) and ~3 additional +aggregators (``hll_sketch`` / ``roaring_bitmap_*``) +are intentionally deferred. Non-INSERT row kinds raise ``NotImplementedError`` at :meth:`add` time so we never silently corrupt data with a half-implemented contract, and out-of-scope aggregator identifiers / options are rejected up-front in