raw_mcv_agg() ERROR: called Option::unwrap()
on a None
value when filter clause is used
#822
Labels
bug
Something isn't working
timescaledb toolkit is the latest from the main branch as of now (1.19.0-dev - beac6d5).
timescaledb is 2.17.0
when refreshing an aggregate, i get this error:
it is caused by this statement in the aggregate sql:
i tracked down the issue to one ticker that has only one record for the specified period and that record is filtered out by the filter clause. this is the complete simplified select:
removing the filter clause makes the select work without issues.
so my guess is, when checking whether there are any records to be aggregated, the filter clause is ignored, which in this case results in no records being provided and crashing on the unwrap.
i did not notice this issue with timescaledb < 1.17.0 before, but i didn't test it now.
The text was updated successfully, but these errors were encountered: