Doesn't env need to be a slot in PipelinedRDD for this to work correctly ?