Bugfix: non-existent manifest not handled gracefully #639

remotes/origin/key_value-onchange
Darko Poljak 7 years ago
parent 2b5f1a0148
commit 3fb7e33305
  1. 2
      cdist/__init__.py

2
cdist/__init__.py vendored

@ -97,7 +97,7 @@ class CdistEntityError(Error):
def stderr(self): def stderr(self):
output = [] output = []
for stderr_name, stderr_path in self.stderr_paths: for stderr_name, stderr_path in self.stderr_paths:
if os.path.getsize(stderr_path) > 0: if os.path.exists(stderr_path) and os.path.getsize(stderr_path) > 0:
label_begin = '---- BEGIN ' + stderr_name + ':stderr ----' label_begin = '---- BEGIN ' + stderr_name + ':stderr ----'
label_end = '---- END ' + stderr_name + ':stderr ----' label_end = '---- END ' + stderr_name + ':stderr ----'
output.append('\n' + label_begin) output.append('\n' + label_begin)

Loading…
Cancel
Save