Handle aggregation errors more gracefully.