-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Closed
Closed
Copy link
Labels
@aws-cdk/aws-lambdaRelated to AWS LambdaRelated to AWS LambdabugThis issue is a bug.This issue is a bug.effort/smallSmall work item – less than a day of effortSmall work item – less than a day of effortp1package/toolsRelated to AWS CDK Tools or CLIRelated to AWS CDK Tools or CLI
Description
Describe the bug
When using a Lambda NodeJsFunction with an alias and a function url attached to it, cdk import always reports pending changes even when no changes exist.
Regression Issue
- Select this option if this issue appears to be a regression.
Last Known Working CDK Version
No response
Expected Behavior
Running cdk import when there are no changes to your lambda function should report no pending changes that need to be resolved on existing resources.
Current Behavior
Running cdk deploy then cdk import always reports resource updates, when no resources are updated.
No resource updates or deletes are allowed on import operation. Make sure to resolve pending changes to existing resources, before attempting an import. Updated/deleted resources: ImportReproStack/ImportReproFunction/Resource, ImportReproFunctionCurrentVersionE3152290f48b63b389af562bcca81f410c827bd9, ImportReproStack/FunctionAlias/Resource (--force to override)
Reproduction Steps
Deploy this stack with cdk deploy
Run cdk import
The cdk template is located here
Possible Solution
Using cdk import --force works, but shouldn't be necessary.
Additional Information/Context
No response
CDK CLI Version
2.160.0 (build 7a8ae02)
Framework Version
2.160.0
Node.js Version
20.13.1
OS
MacOS Sonoma 14.6.1
Language
TypeScript
Language Version
No response
Other information
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
@aws-cdk/aws-lambdaRelated to AWS LambdaRelated to AWS LambdabugThis issue is a bug.This issue is a bug.effort/smallSmall work item – less than a day of effortSmall work item – less than a day of effortp1package/toolsRelated to AWS CDK Tools or CLIRelated to AWS CDK Tools or CLI