SERVER-137999ClosedFixed
Join optimization NLJ with a sub-pipeline-projected foreign node as the outer side hits tassert
Plan HJ(NLJ(PROJECTION_DEFAULT(COLLSCAN b), COLLSCAN a), COLLSCAN c) where b's sub-pipeline $project renames the field the second join reads (b.y). The NLJ stage builder in gen_lookup.cpp does not export the renamed slot from the outer side, and the plan fails at prepare time.