catch error when num_bg_jobs is not defined