Skip to content

Commit

Permalink
Bugfix: make space saving aggregate serialization strict
Browse files Browse the repository at this point in the history
follows in the footsteps of #351 in making space saving aggregate serialization strict for frequency aggregates to avoid NULL partitions causing Unwrap errors on 'None' values



Signed-off-by: Travis Vander Hoop <[email protected]>
  • Loading branch information
vanderhoop authored Oct 20, 2024
1 parent beac6d5 commit 9cae284
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion extension/src/frequency.rs
Original file line number Diff line number Diff line change
Expand Up @@ -956,7 +956,7 @@ fn space_saving_text_final(
state.map(SpaceSavingTextAggregate::from)
}

#[pg_extern(immutable, parallel_safe)]
#[pg_extern(immutable, parallel_safe, strict)]
fn space_saving_serialize(state: Internal) -> bytea {
let state: Inner<SpaceSavingTransState> = unsafe { state.to_inner().unwrap() };
crate::do_serialize!(state)
Expand Down

0 comments on commit 9cae284

Please sign in to comment.