databrickslabs / remorph

Cross-compiler and Data Reconciler into Databricks Lakehouse
Other
28 stars 16 forks source link

[BUG]: Aggregation reconciliation is failing abruptly #789

Closed ganeshdogiparthi-db closed 1 week ago

ganeshdogiparthi-db commented 1 month ago

Is there an existing issue for this?

Category of Bug / Issue

ReconcileError

Current Behavior

Aggregation reconciliation is failing with below error

TypeError: reduce() of empty iterable with no initial value

TypeError Traceback (most recent call last) File , line 8 4 return reduce(lambda agg_df, df: agg_df.unionByName(df), df_list) 7 df = spark.sql("select * from data.testing.telecommunication_data") ----> 8 _union_dataframes([]).display()

File , line 4, in _union_dataframes(df_list) 3 def _union_dataframes(df_list: list[DataFrame]) -> DataFrame: ----> 4 return reduce(lambda agg_df, df: agg_df.unionByName(df), df_list)

Expected Behavior

No response

Steps To Reproduce

No response

Relevant log output or Exception details

No response

Sample Query

No response

Operating System

macOS

Version

latest via Databricks CLI

vijaypavann-db commented 1 week ago

Handled in #740 #784