Can't remove function #13439
Labels
functions
Issues tied to the functions category
pending-response
Issue is pending response from the issue author
pending-triage
Issue is pending triage
How did you install the Amplify CLI?
npm
If applicable, what version of Node.js are you using?
v18.18.0
Amplify CLI Version
12.7.1
What operating system are you using?
Mac
Did you make any manual changes to the cloud resources managed by Amplify? Please describe the changes made.
No manual changes made
Describe the bug
Our team created a function that is triggered by a DynamoDB stream. It was deployed successfully. A team member then ran amplify push without first pulling the function into their codebase. This caused the function and triggers to be removed. The stream and CloudWatch log groups were left in place. The team member then pulled the function locally and ran amplify push. No changes were detected. A duplicate function under an alternate name was created and successfully deployed. Attempts to remove the old function prompted the creation of this bug report.
Expected behavior
The old function is removed.
Reproduction steps
Create a function and commit
Amplify push
Open the project without the added function (don't pull the commit)
Make a schema change and Amplify push
Pull the commit with the function
Amplify push (We expected this to fix the issue)
Create a new function under a different name
Amplify push
Amplify remove original function
Project Identifier
513f9a125170cf19b4d2e61fe787ec2e
Log output
Additional information
No response
Before submitting, please confirm:
The text was updated successfully, but these errors were encountered: