retry project creation status check 10 times instead of 5

This commit is contained in:
Jay Lee
2022-07-15 11:08:36 -04:00
committed by GitHub
parent 4ef5606f05
commit 3216666a94

View File

@@ -7555,7 +7555,7 @@ def doCreateProject():
create_operation = gapi.call(crm.projects(), 'create', body=body)
operation_name = create_operation['name']
time.sleep(8) # Google recommends always waiting at least 5 seconds
for i in range(1, 5):
for i in range(1, 10):
print('Checking project status...')
status = gapi.call(crm.operations(), 'get', name=operation_name)
if 'error' in status: