Skip to content
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

feat(s3): update runtime of notifications-handler to python3.9 #23209

Merged
merged 7 commits into from Dec 7, 2022

Conversation

watany-dev
Copy link
Contributor

closes #20973

This upgrades the runtime of the internal function notifications-resource-handler from Python 3.7 to Python 3.9

Referring to the PR below
#21483


All Submissions:

Adding new Construct Runtime Dependencies:

  • This PR adds new construct runtime dependencies following the process described here

New Features

  • Have you added the new feature to an integration test?
    • Did you use yarn integ to deploy the infrastructure and generate the snapshot (i.e. yarn integ without --dry-run)?

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

@gitpod-io
Copy link

gitpod-io bot commented Dec 2, 2022

@github-actions github-actions bot added the p1 label Dec 2, 2022
@aws-cdk-automation aws-cdk-automation requested a review from a team December 2, 2022 16:28
@github-actions github-actions bot added the admired-contributor [Pilot] contributed between 13-24 PRs to the CDK label Dec 2, 2022
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.

The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.

@watany-dev watany-dev changed the title fix(s3): Runtime modernization of notifications-handler fix(s3): Upgrade Runtime to Python 3.9 of notifications-handler Dec 2, 2022
@watany-dev
Copy link
Contributor Author

watany-dev commented Dec 2, 2022

I have updated the existing integ-test and verified that it is the updated runtime. Do I need to create any more new tests?

@watany-dev
Copy link
Contributor Author

The updated integ test seems to have an error if the new module is not used. Will address this tomorrow.

@aws-cdk-automation aws-cdk-automation dismissed their stale review December 5, 2022 13:59

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

@mrgrain mrgrain self-assigned this Dec 5, 2022
@mrgrain
Copy link
Contributor

mrgrain commented Dec 5, 2022

Code looks good. I checked and python3.9 is available everywhere we need it.

Once the test passes, this should be good to ship.

@mrgrain mrgrain changed the title fix(s3): Upgrade Runtime to Python 3.9 of notifications-handler fix(s3): upgrade Runtime to Python 3.9 of notifications-handler Dec 5, 2022
@mrgrain mrgrain changed the title fix(s3): upgrade Runtime to Python 3.9 of notifications-handler feat(s3): update runtime of notifications-handler to python3.9 Dec 5, 2022
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.

The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.

@mrgrain mrgrain added the pr-linter/exempt-readme The PR linter will not require README changes label Dec 5, 2022
@aws-cdk-automation aws-cdk-automation dismissed their stale review December 5, 2022 15:16

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

@mrgrain mrgrain added p2 and removed p1 labels Dec 5, 2022
@watany-dev
Copy link
Contributor Author

Glad to have your review.
I checked and it looks like the integ test needed @s3-notification as well as @s3. I'm currently waiting for the results of a push that resolves this.

@watany-dev
Copy link
Contributor Author

@mrgrain
We were able to confirm the PASS of all tests.

mrgrain
mrgrain previously requested changes Dec 6, 2022
Copy link
Contributor

@mrgrain mrgrain left a comment

Choose a reason for hiding this comment

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

Just a minor thing.

But I'll need some more time to look at these integ tests. I'm a bit surprised so many snapshots need updating.

Comment on lines -1 to +6
import { md5hash } from '@aws-cdk/core/lib/helpers-internal';
import { ISecurityGroup, IVpc, SubnetSelection } from '@aws-cdk/aws-ec2';
import * as iam from '@aws-cdk/aws-iam';
import * as lambda from '@aws-cdk/aws-lambda';
import * as secretsmanager from '@aws-cdk/aws-secretsmanager';
import { Stack, Names } from '@aws-cdk/core';
import { md5hash } from '@aws-cdk/core/lib/helpers-internal';
Copy link
Contributor

Choose a reason for hiding this comment

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

Would you mind reverting this unrelated change. Thanks.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This error was automatically fixed by yarn build --fix before integ-test.
Do I still need to fix it now that the test has passed because the IDE outputs the following Warning.

Import of `@aws-cdk/core/lib/helpers-internal` must be done after import of `@aws-cdk/core`.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Nevertheless, I have added the commit to be corrected as requested.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah I see, thanks for explaining where this came from. 👍🏻 Probably would have been fine to leave it in then. From a PR review it's difficult to establish the source of these kind of changes (and manually checking would just take to long).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sorry I was in a hurry to fix it. This commit should bring us back to the beginning of this review!

Copy link
Contributor

Choose a reason for hiding this comment

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

All good and thank you for being diligent. It's a tricky thing. When the same module has other change I usually don't question it.

Maybe adding a comment to the line on GitHub would help reviewers. 🤔

@mergify mergify bot dismissed mrgrain’s stale review December 6, 2022 23:58

Pull request has been modified.

@mrgrain
Copy link
Contributor

mrgrain commented Dec 7, 2022

This looks all good. I'm currently looking into adding an extended test that actually tests the notification delivery. Not sure if it's possible though.

Copy link
Contributor

@mrgrain mrgrain left a comment

Choose a reason for hiding this comment

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

🚀

@mergify
Copy link
Contributor

mergify bot commented Dec 7, 2022

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

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

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

@mergify mergify bot merged commit b2d293d into aws:main Dec 7, 2022
@mergify
Copy link
Contributor

mergify bot commented Dec 7, 2022

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@watany-dev watany-dev deleted the bucket-noti-py3.9 branch December 7, 2022 22:09
brennanho pushed a commit to brennanho/aws-cdk that referenced this pull request Dec 9, 2022
…3209)

closes aws#20973

This upgrades the runtime of the internal function `notifications-resource-handler` from Python 3.7 to Python 3.9

Referring to the PR below
aws#21483

----

### All Submissions:

* [ ] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md)

### Adding new Construct Runtime Dependencies:

* [ ] This PR adds new construct runtime dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-construct-runtime-dependencies)

### New Features

* [ ] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)?
	* [ ] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)?

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
brennanho pushed a commit to brennanho/aws-cdk that referenced this pull request Jan 20, 2023
…3209)

closes aws#20973

This upgrades the runtime of the internal function `notifications-resource-handler` from Python 3.7 to Python 3.9

Referring to the PR below
aws#21483

----

### All Submissions:

* [ ] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md)

### Adding new Construct Runtime Dependencies:

* [ ] This PR adds new construct runtime dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-construct-runtime-dependencies)

### New Features

* [ ] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)?
	* [ ] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)?

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
brennanho pushed a commit to brennanho/aws-cdk that referenced this pull request Feb 22, 2023
…3209)

closes aws#20973

This upgrades the runtime of the internal function `notifications-resource-handler` from Python 3.7 to Python 3.9

Referring to the PR below
aws#21483

----

### All Submissions:

* [ ] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md)

### Adding new Construct Runtime Dependencies:

* [ ] This PR adds new construct runtime dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-construct-runtime-dependencies)

### New Features

* [ ] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)?
	* [ ] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)?

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
admired-contributor [Pilot] contributed between 13-24 PRs to the CDK p2 pr-linter/exempt-readme The PR linter will not require README changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

@aws-cdk/aws-s3 : s3 bucket python version upgrade
3 participants