-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Get "ResourceConflictException" after opt-in AWS lambda states update #415
Comments
@RonWang I can confirm this issue which affects the In all, the |
I'm having this issue since this morning deploying in the eu-west-1 region. |
Set the function description to "aws:states:opt-out" to deploy again. |
Any update here? I'm using the |
Any updates? I'm also experiencing the same problem as other engineers here. My workflow will be blocked as of 12/6 and this is the main SDK to deploy Alexa Skills with lambda functions. |
Looks like it's a problem with how we use revision id when updating lambda function. Tracing that code: CLI will load the Lambda Function information from AWS and store it in
Then, when updating the Lambda, the
And then uses it when updating the Function: ask-cli/lib/builtins/deploy-delegates/lambda-deployer/helper.js Lines 241 to 250 in b6fb7b9
It calls UpdateFunctionConfiguration afterwards but it uses the latest RevisionId:
From the conversation here, this seems to be related to AWS Lambda States. Reading the docs: https://docs.aws.amazon.com/lambda/latest/dg/functions-states.html
I think the fix is to wait until the state changes before calling UpdateFunctionConfiguration. |
Hey all, sorry for the delay on this. I've put together a PR for what I think should fix this issue. Still need to test but would also like some feedback on the desired behavior: #422 |
I will test this once I get back in to the office. Until then, feel free to check out #422 and run the following commands to install it as your CLI
|
Hi @sam-goodwin, thank you for the update on this issue, I will be watching your PR, based on the latest comments sounds like I should wait to update to the newer version, will keep an eye out. |
If anyone want to test the PR I submitted above, you can install it using the command below:
|
Hi @jsetton my tests were successful with your branch, I was able to deploy latest code changes to my lambda function code to AWS without issues. It's looking good on my end. My understanding is that your code still have to finish going through review before a new release can be rolled out correct? |
Really appreciate your work so far @jsetton ! |
This is correct but you can use the version I submitted in the meantime. Since ask-cli checks for the latest available official release each time you run the tool, you will be notified when to switch back to the official one. |
I'm submitting a...
Expected Behavior
It should deploy lambda successfully when I opt-in AWS lambda states update.
Current Behavior
I follow the Coming soon: Expansion of AWS Lambda states to all functions to add
aws:states:opt-in
in function’s description. Running ask deploy will failed and get error message:If I remove
aws:states:opt-in
in function’s description, it can deploy normally.Your Environment and Context
The text was updated successfully, but these errors were encountered: