소스 검색

Merge pull request #5300 from mtnbikenc/fix-ansible_syntax-check

Fix ansible_syntax check
Scott Dodson 7 년 전
부모
커밋
4acf08d76c
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      setup.py

+ 1 - 1
setup.py

@@ -58,7 +58,7 @@ def find_entrypoint_playbooks():
             os.path.join(os.getcwd(), 'playbooks'),
             exclude_dirs, None, r'\.ya?ml$'):
         with open(yaml_file, 'r') as contents:
-            for task in yaml.safe_load(contents):
+            for task in yaml.safe_load(contents) or {}:
                 if not isinstance(task, dict):
                     # Skip yaml files which are not a dictionary of tasks
                     continue