mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-08 14:22:46 +00:00
Update bare exceptions to specify Exception.
This will keep us from accidentally catching program-exiting exceptions like KeyboardInterupt and SystemExit.
This commit is contained in:
@@ -234,7 +234,7 @@ if __name__ == '__main__':
|
||||
if not os.path.exists(jobdir):
|
||||
try:
|
||||
os.makedirs(jobdir)
|
||||
except:
|
||||
except Exception:
|
||||
print(json.dumps({
|
||||
"failed": 1,
|
||||
"msg": "could not create: %s" % jobdir
|
||||
|
||||
Reference in New Issue
Block a user