Lambda update fails with ResourceConflictException
See original GitHub issueContext
Since today the zappa update
method fails with the following error:
Downloading and installing dependencies..
Packaging project as zip.
Uploading ***********-1631808391.tar.gz (50.2MiB)..
100% 52.6M/52.6M [00:00<00:00, 101MB/s]
Uploading handler_***********-1631808473.zip (14.5MiB)..
100% 15.2M/15.2M [00:00<00:00, 43.1MB/s]
Updating Lambda function code..
Updating Lambda function configuration..
Oh no! An error occurred! :(
==============
Traceback (most recent call last):
File "/root/repo/venv/lib/python3.6/site-packages/zappa/cli.py", line 2785, in handle
sys.exit(cli.handle())
File "/root/repo/venv/lib/python3.6/site-packages/zappa/cli.py", line 510, in handle
self.dispatch_command(self.command, stage)
File "/root/repo/venv/lib/python3.6/site-packages/zappa/cli.py", line 557, in dispatch_command
self.update(self.vargs['zip'], self.vargs['no_upload'])
File "/root/repo/venv/lib/python3.6/site-packages/zappa/cli.py", line 975, in update
aws_kms_key_arn=self.aws_kms_key_arn,
File "/root/repo/venv/lib/python3.6/site-packages/zappa/core.py", line 1203, in update_lambda_configuration
'Mode': 'Active' if self.xray_tracing else 'PassThrough'
File "/root/repo/venv/lib/python3.6/site-packages/botocore/client.py", line 386, in _api_call
return self._make_api_call(operation_name, kwargs)
File "/root/repo/venv/lib/python3.6/site-packages/botocore/client.py", line 705, in _make_api_call
raise error_class(parsed_response, operation_name)
botocore.errorfactory.ResourceConflictException: An error occurred (ResourceConflictException) when calling the UpdateFunctionConfiguration operation: The operation cannot be performed at this time. An update is in progress for resource: arn:aws:lambda:us-east-********:function:***********
==============
It seems like lambda introduced function states
and the state needs to be checked during deployment.
https://forums.aws.amazon.com/thread.jspa?messageID=995846󳈆
In the error above this means that the state needs to be checked after Updating Lambda function code and before Updating Lambda function configuration
Is there already a fix for this issue?
Issue Analytics
- State:
- Created 2 years ago
- Reactions:5
- Comments:18
Top Results From Across the Web
An update is in progress for resource - AWS re:Post
After deploying (update) a Lambda for about 150 times in an automated way using CI, this suddenly fails since in `eu-west-1` since 2021-09-14...
Read more >AWS lambda ResourceConflictException on deployment
When I do that locally, it fails when deploying the environment, on jenkins it always fails when deploying the code. I'm not sure...
Read more >UpdateFunctionConfiguration - AWS Lambda
When you update a function, Lambda provisions an instance of the function and its supporting resources. If your function connects to a VPC,...
Read more >Dpl lambda fails to deploy: "An update is in progress for ...
Hi, All of a sudden TravisCI fails to deploy some lambda functions (which have been deployed successfully in the past). running dpl command ......
Read more >Yak shaving series #2: A tale of 12 errors | by Yevgeniy Brikman
We have a reusable Terraform module for deploying to AWS Lambda in just a few lines of code: module "app" { ... Error...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
As a workaround, until October 1, you can opt-out. Add to your zappa_settings.json:
Confirming that updating Zappa to v0.54.1 and troposphere to v3.0 got me past this problem.