Fix empty deps file generation on failure