better error handling in collect_env
better error handling in collect_env

Reviewed By: alexander-kirillov

Differential Revision: D28025375

fbshipit-source-id: 434697cf2b08b2011f1ee9d8fc8d9b595f103553

facebookresearch/detectron2,facebookresearch/detectron2,facebookresearch/detectron2