Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions lambda_uploader/uploader.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,11 @@ def upload_existing(self, pkg):
)
LOG.debug("AWS update_function_code response: %s"
% conf_update_resp)

waiter = self._lambda_client.get_waiter('function_updated')
LOG.debug("Waiting for lambda function to be updated")
waiter.wait(FunctionName=self._config.name)

LOG.debug('running update_function_configuration')
response = self._lambda_client.update_function_configuration(
FunctionName=self._config.name,
Expand All @@ -80,6 +85,11 @@ def upload_existing(self, pkg):
version = response.get('Version')
# Publish the version after upload and config update if needed
if self._config.publish:

waiter = self._lambda_client.get_waiter('function_updated')
LOG.debug("Waiting for lambda function to be updated")
waiter.wait(FunctionName=self._config.name)

resp = self._lambda_client.publish_version(
FunctionName=self._config.name,
)
Expand Down