Details
Description
$project, $addFields and $set that reference the metaField are pushed before the $_internalUnpackBucket stage. However, we are not accounting for the case that these stages could have expressions with subexpressions that are dependent on measurement fields. Below is a minimal repro from a fuzzer BF.