Skip to content

docs(lambda): warn users on using fromBucket without setting objectVersion #34772

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Abogical
Copy link
Member

Issue #6176

Closes #6176.

Reason for this change

Using fromBucket to source lambda code can have the unintended silent effect of not updating when the code is updated on the S3 bucket.

Description of changes

  • A note is added to the docs on this beahvior
  • A warning is added if objectVersion is not set.

Describe any new or updated permissions being added

No permissions added.

Description of how you validated changes

Unit tests to confirm the emission of warnings only if an object version is not set.

Checklist


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

@aws-cdk-automation aws-cdk-automation requested a review from a team June 20, 2025 12:52
@github-actions github-actions bot added repeat-contributor [Pilot] contributed between 3-5 PRs to the CDK bug This issue is a bug. effort/small Small work item – less than a day of effort p1 labels Jun 20, 2025
Copy link
Collaborator

@aws-cdk-automation aws-cdk-automation left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(This review is outdated)

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildv2Project1C6BFA3F-wQm2hXv2jqQv
  • Commit ID: 6884652
  • Result: FAILED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@Abogical Abogical changed the title docs(aws-lambda): Warn users on using fromBucket without setting objectVersion docs(lambda): Warn users on using fromBucket without setting objectVersion Jun 20, 2025
@Abogical Abogical changed the title docs(lambda): Warn users on using fromBucket without setting objectVersion docs(lambda): warn users on using fromBucket without setting objectVersion Jun 20, 2025
@aws-cdk-automation aws-cdk-automation dismissed their stale review June 20, 2025 13:23

✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. effort/small Small work item – less than a day of effort p1 repeat-contributor [Pilot] contributed between 3-5 PRs to the CDK
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lambda Function Code.FromBucket() does not update "Code Entry Type" in AWS console
2 participants