Skip to content

Commit 0292b91

Browse files
authored
Merge pull request #3 from sclausson/master
Convert SLEEP_TIME to integer
2 parents 4b18251 + cdc505b commit 0292b91

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

index/index.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def lambda_handler(event, context):
5353
if instance_has_running_tasks(msg['EC2InstanceId']):
5454
print('Tasks are still running on instance %s; posting msg to SNS topic %s' %
5555
(msg['EC2InstanceId'], event['Records'][0]['Sns']['TopicArn']))
56-
time.sleep(SLEEP_TIME)
56+
time.sleep(int(SLEEP_TIME))
5757
sns_resp = SNS.publish(TopicArn=event['Records'][0]['Sns']['TopicArn'],
5858
Message=json.dumps(msg),
5959
Subject='Publishing SNS msg to invoke Lambda again.')

0 commit comments

Comments
 (0)