Skip to content

Commit 112df0e

Browse files
Merge branch 'develop' into impl-prototype-async-execution-resolver
2 parents 2fdeba6 + 2a7a9aa commit 112df0e

File tree

208 files changed

+5895
-3148
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

208 files changed

+5895
-3148
lines changed

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@ body:
5858
attributes:
5959
label: AWS Lambda function runtime
6060
options:
61-
- "3.8"
6261
- "3.9"
6362
- "3.10"
6463
- "3.11"

.github/ISSUE_TEMPLATE/static_typing.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ body:
2525
attributes:
2626
label: AWS Lambda function runtime
2727
options:
28-
- "3.8"
2928
- "3.9"
3029
- "3.10"
3130
- "3.11"
Lines changed: 110 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
name: Region Bootstrap
2+
3+
# bootstraps new regions
4+
#
5+
# PURPOSE
6+
# Ensures new regions are deployable in future releases
7+
#
8+
# JOB 1 PROCESS
9+
#
10+
# 1. Installs CDK
11+
# 2. Bootstraps region
12+
#
13+
# JOB 2 PROCESS
14+
# 1. Sets up Go
15+
# 2. Installs the balance script
16+
# 3. Runs balance script to copy layers between aws regions
17+
18+
on:
19+
workflow_dispatch:
20+
inputs:
21+
environment:
22+
type: choice
23+
options:
24+
- beta
25+
- prod
26+
description: Deployment environment
27+
region:
28+
type: string
29+
required: true
30+
description: AWS region to bootstrap (i.e. eu-west-1)
31+
32+
run-name: Region Bootstrap ${{ inputs.region }}
33+
34+
permissions:
35+
contents: read
36+
37+
jobs:
38+
cdk:
39+
name: Install CDK
40+
runs-on: ubuntu-latest
41+
permissions:
42+
contents: read
43+
id-token: write
44+
environment: layer-${{ inputs.environment }}
45+
steps:
46+
- id: credentials
47+
name: AWS Credentials
48+
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4.0.2
49+
with:
50+
aws-region: ${{ inputs.region }}
51+
role-to-assume: ${{ secrets.REGION_IAM_ROLE }}
52+
mask-aws-account-id: true
53+
- id: workdir
54+
name: Create Workdir
55+
run: |
56+
mkdir -p build/project
57+
- id: cdk-install
58+
name: Install CDK
59+
working-directory: build
60+
run: |
61+
npm i aws-cdk
62+
- id: cdk-project
63+
name: CDK Project
64+
working-directory: build/project
65+
run: |
66+
npx cdk init app --language=typescript
67+
AWS_REGION="${{ inputs.region }}" npx cdk bootstrap
68+
69+
copy_layers:
70+
name: Copy Layers
71+
runs-on: ubuntu-latest
72+
permissions:
73+
contents: read
74+
id-token: write
75+
strategy:
76+
matrix:
77+
layer:
78+
- AWSLambdaPowertoolsPythonV3-python38-arm64
79+
- AWSLambdaPowertoolsPythonV3-python39-arm64
80+
- AWSLambdaPowertoolsPythonV3-python310-arm64
81+
- AWSLambdaPowertoolsPythonV3-python311-arm64
82+
- AWSLambdaPowertoolsPythonV3-python312-arm64
83+
- AWSLambdaPowertoolsPythonV3-python313-arm64
84+
- AWSLambdaPowertoolsPythonV3-python38-x86_64
85+
- AWSLambdaPowertoolsPythonV3-python39-x86_64
86+
- AWSLambdaPowertoolsPythonV3-python310-x86_64
87+
- AWSLambdaPowertoolsPythonV3-python311-x86_64
88+
- AWSLambdaPowertoolsPythonV3-python312-x86_64
89+
- AWSLambdaPowertoolsPythonV3-python313-x86_64
90+
environment: layer-${{ inputs.environment }}
91+
steps:
92+
- id: credentials
93+
name: AWS Credentials
94+
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4.0.2
95+
with:
96+
aws-region: us-east-1
97+
role-to-assume: ${{ secrets.REGION_IAM_ROLE }}
98+
mask-aws-account-id: true
99+
- id: go-setup
100+
name: Setup Go
101+
uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
102+
- id: go-env
103+
name: Go Env
104+
run: go env
105+
- id: go-install-pkg
106+
name: Install
107+
run: go install github.com/aws-powertools/actions/layer-balancer/cmd/balance@latest
108+
- id: run-balance
109+
name: Run Balance
110+
run: balance -read-region us-east-1 -write-region ${{ inputs.region }} -write-role ${{ secrets.BALANCE_ROLE_ARN }} -layer-name ${{ matrix.layer }} -dry-run=false

.github/workflows/dispatch_analytics.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,11 @@ jobs:
4343
statuses: read
4444
steps:
4545
- name: Configure AWS credentials
46-
uses: aws-actions/configure-aws-credentials@5fd3084fc36e372ff1fff382a39b10d03659f355 # v2.2.0
46+
uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4.0.2
4747
with:
4848
aws-region: eu-central-1
49-
role-to-assume: ${{ secrets.AWS_ANALYTICS_ROLE_ARN }}
49+
role-to-assume: ${{ secrets.AWS_LAYERS_ROLE_ARN }}
50+
mask-aws-account-id: true
5051

5152
- name: Invoke Lambda function
5253
run: |

.github/workflows/layer_govcloud.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
name: Layer Deployment (GovCloud)
2+
13
# GovCloud Layer Publish
24
# ---
35
# This workflow publishes a specific layer version in an AWS account based on the environment input.
@@ -32,9 +34,11 @@ on:
3234
type: string
3335
required: true
3436

35-
name: Layer Deployment (GovCloud)
3637
run-name: Layer Deployment (GovCloud) - ${{ inputs.environment }}
3738

39+
permissions:
40+
contents: read
41+
3842
jobs:
3943
download:
4044
runs-on: ubuntu-latest
@@ -44,7 +48,6 @@ jobs:
4448
strategy:
4549
matrix:
4650
layer:
47-
- AWSLambdaPowertoolsPythonV3-python38
4851
- AWSLambdaPowertoolsPythonV3-python39
4952
- AWSLambdaPowertoolsPythonV3-python310
5053
- AWSLambdaPowertoolsPythonV3-python311
@@ -66,14 +69,14 @@ jobs:
6669
aws --region us-east-1 lambda get-layer-version-by-arn --arn arn:aws:lambda:us-east-1:017000801446:layer:${{ matrix.layer }}-${{ matrix.arch }}:${{ inputs.version }} --query 'Content.Location' | xargs curl -L -o ${{ matrix.layer }}_${{ matrix.arch }}.zip
6770
aws --region us-east-1 lambda get-layer-version-by-arn --arn arn:aws:lambda:us-east-1:017000801446:layer:${{ matrix.layer }}-${{ matrix.arch }}:${{ inputs.version }} > ${{ matrix.layer }}_${{ matrix.arch }}.json
6871
- name: Store Zip
69-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
72+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
7073
with:
7174
name: ${{ matrix.layer }}_${{ matrix.arch }}.zip
7275
path: ${{ matrix.layer }}_${{ matrix.arch }}.zip
7376
retention-days: 1
7477
if-no-files-found: error
7578
- name: Store Metadata
76-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
79+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
7780
with:
7881
name: ${{ matrix.layer }}_${{ matrix.arch }}.json
7982
path: ${{ matrix.layer }}_${{ matrix.arch }}.json
@@ -90,7 +93,6 @@ jobs:
9093
strategy:
9194
matrix:
9295
layer:
93-
- AWSLambdaPowertoolsPythonV3-python38
9496
- AWSLambdaPowertoolsPythonV3-python39
9597
- AWSLambdaPowertoolsPythonV3-python310
9698
- AWSLambdaPowertoolsPythonV3-python311
@@ -159,7 +161,6 @@ jobs:
159161
strategy:
160162
matrix:
161163
layer:
162-
- AWSLambdaPowertoolsPythonV3-python38
163164
- AWSLambdaPowertoolsPythonV3-python39
164165
- AWSLambdaPowertoolsPythonV3-python310
165166
- AWSLambdaPowertoolsPythonV3-python311

.github/workflows/layer_govcloud_python313.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
name: Layer Deployment (GovCloud) - Temporary for Python 3.13
2+
13
# GovCloud Layer Publish
24
# ---
35
# This workflow publishes a specific layer version in an AWS account based on the environment input.
@@ -32,9 +34,11 @@ on:
3234
type: string
3335
required: true
3436

35-
name: Layer Deployment (GovCloud) - Temporary for Python 3.13
3637
run-name: Layer Deployment (GovCloud) - ${{ inputs.environment }}
3738

39+
permissions:
40+
contents: read
41+
3842
jobs:
3943
download:
4044
runs-on: ubuntu-latest
@@ -61,14 +65,14 @@ jobs:
6165
aws --region us-east-1 lambda get-layer-version-by-arn --arn arn:aws:lambda:us-east-1:017000801446:layer:${{ matrix.layer }}-${{ matrix.arch }}:${{ inputs.version }} --query 'Content.Location' | xargs curl -L -o ${{ matrix.layer }}_${{ matrix.arch }}.zip
6266
aws --region us-east-1 lambda get-layer-version-by-arn --arn arn:aws:lambda:us-east-1:017000801446:layer:${{ matrix.layer }}-${{ matrix.arch }}:${{ inputs.version }} > ${{ matrix.layer }}_${{ matrix.arch }}.json
6367
- name: Store Zip
64-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
68+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
6569
with:
6670
name: ${{ matrix.layer }}_${{ matrix.arch }}.zip
6771
path: ${{ matrix.layer }}_${{ matrix.arch }}.zip
6872
retention-days: 1
6973
if-no-files-found: error
7074
- name: Store Metadata
71-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
75+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
7276
with:
7377
name: ${{ matrix.layer }}_${{ matrix.arch }}.json
7478
path: ${{ matrix.layer }}_${{ matrix.arch }}.json

.github/workflows/layer_govcloud_verify.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ jobs:
2828
strategy:
2929
matrix:
3030
layer:
31-
- AWSLambdaPowertoolsPythonV3-python38
3231
- AWSLambdaPowertoolsPythonV3-python39
3332
- AWSLambdaPowertoolsPythonV3-python310
3433
- AWSLambdaPowertoolsPythonV3-python311
@@ -59,7 +58,6 @@ jobs:
5958
strategy:
6059
matrix:
6160
layer:
62-
- AWSLambdaPowertoolsPythonV3-python38
6361
- AWSLambdaPowertoolsPythonV3-python39
6462
- AWSLambdaPowertoolsPythonV3-python310
6563
- AWSLambdaPowertoolsPythonV3-python311
@@ -91,7 +89,6 @@ jobs:
9189
strategy:
9290
matrix:
9391
layer:
94-
- AWSLambdaPowertoolsPythonV3-python38
9592
- AWSLambdaPowertoolsPythonV3-python39
9693
- AWSLambdaPowertoolsPythonV3-python310
9794
- AWSLambdaPowertoolsPythonV3-python311

.github/workflows/layer_rename.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,14 +66,14 @@ jobs:
6666
aws --region us-east-1 lambda get-layer-version-by-arn --arn arn:aws:lambda:us-east-1:017000801446:layer:${{ matrix.layer }}-x86:${{ inputs.version }} --query 'Content.Location' | xargs curl -L -o ${{ matrix.layer }}_x86_64.zip
6767
aws --region us-east-1 lambda get-layer-version-by-arn --arn arn:aws:lambda:us-east-1:017000801446:layer:${{ matrix.layer }}-x86:${{ inputs.version }} > ${{ matrix.layer }}_x86_64.json
6868
- name: Store Zip
69-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
69+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
7070
with:
7171
name: ${{ matrix.layer }}_x86_64.zip
7272
path: ${{ matrix.layer }}_x86_64.zip
7373
retention-days: 1
7474
if-no-files-found: error
7575
- name: Store Metadata
76-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
76+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
7777
with:
7878
name: ${{ matrix.layer }}_x86_64.json
7979
path: ${{ matrix.layer }}_x86_64.json

.github/workflows/on_closed_issues.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
permissions:
2222
issues: write # comment on issues
2323
steps:
24-
- uses: aws-actions/closed-issue-message@37548691e7cc75ba58f85c9f873f9eee43590449
24+
- uses: aws-powertools/actions/.github/actions/close-issue-message@428c1934f4b22c0984ff4a39b66c2f70765bbed6
2525
with:
2626
repo-token: "${{ secrets.GITHUB_TOKEN }}"
2727
message: |

.github/workflows/ossf_scorecard.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
repo_token: ${{ secrets.SCORECARD_TOKEN }} # read-only fine-grained token to read branch protection settings
3636

3737
- name: "Upload results"
38-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
38+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
3939
with:
4040
name: SARIF file
4141
path: results.sarif

.github/workflows/pre-release.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,8 @@ jobs:
6363
# We use a pinned version of Poetry to be certain it won't modify source code before we create a hash
6464
- name: Install poetry
6565
run: |
66-
pipx install git+https://github.com/python-poetry/poetry@68b88e5390720a3dd84f02940ec5200bfce39ac6 # v1.5.0
67-
pipx inject poetry git+https://github.com/monim67/poetry-bumpversion@315fe3324a699fa12ec20e202eb7375d4327d1c4 # v0.3.1
66+
pipx install git+https://github.com/python-poetry/poetry@bd500dd3bdfaec3de6894144c9cedb3a9358be84 # v2.0.1
67+
pipx inject poetry git+https://github.com/monim67/poetry-bumpversion@348de6f247222e2953d649932426e63492e0a6bf # v0.3.3
6868
6969
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
7070
with:
@@ -124,7 +124,7 @@ jobs:
124124
run: cat pyproject.toml
125125

126126
- name: Install poetry
127-
run: pipx install git+https://github.com/python-poetry/poetry@68b88e5390720a3dd84f02940ec5200bfce39ac6 # v1.5.0
127+
run: pipx install git+https://github.com/python-poetry/poetry@bd500dd3bdfaec3de6894144c9cedb3a9358be84 # v2.0.1
128128
- name: Set up Python
129129
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
130130
with:
@@ -162,7 +162,7 @@ jobs:
162162
artifact_name: ${{ needs.seal.outputs.artifact_name }}
163163

164164
- name: Install poetry
165-
run: pipx install git+https://github.com/python-poetry/poetry@68b88e5390720a3dd84f02940ec5200bfce39ac6 # v1.5.0
165+
run: pipx install git+https://github.com/python-poetry/poetry@bd500dd3bdfaec3de6894144c9cedb3a9358be84 # v2.0.1
166166
- name: Set up Python
167167
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
168168
with:
@@ -232,7 +232,7 @@ jobs:
232232

233233
- name: Upload to PyPi prod
234234
if: ${{ !inputs.skip_pypi }}
235-
uses: pypa/gh-action-pypi-publish@15c56dba361d8335944d31a2ecd17d700fc7bcbc # v1.12.2
235+
uses: pypa/gh-action-pypi-publish@67339c736fd9354cd4f8cb0b744f2b82a74b5c70 # v1.12.3
236236

237237
# Creates a PR with the latest version we've just released
238238
# since our trunk is protected against any direct pushes from automation

.github/workflows/publish_v2_layer.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ jobs:
9999
artifact_name: ${{ inputs.source_code_artifact_name }}
100100

101101
- name: Install poetry
102-
run: pipx install git+https://github.com/python-poetry/poetry@68b88e5390720a3dd84f02940ec5200bfce39ac6 # v1.5.0
102+
run: pipx install git+https://github.com/python-poetry/poetry@bd500dd3bdfaec3de6894144c9cedb3a9358be84 # v2.0.1
103103
- name: Setup Node.js
104104
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
105105
with:
@@ -124,7 +124,7 @@ jobs:
124124

125125
- name: Set up Docker Buildx
126126
id: builder
127-
uses: docker/setup-buildx-action@c47758b77c9736f4b2ef4073d4d51994fabfe349 # v3.7.1
127+
uses: docker/setup-buildx-action@6524bf65af31da8d45b59e8c27de4bd072b392f5 # v3.8.0
128128
with:
129129
install: true
130130
driver: docker
@@ -146,7 +146,7 @@ jobs:
146146
- name: zip output
147147
run: zip -r cdk.out.zip cdk.out
148148
- name: Archive CDK artifacts
149-
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
149+
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
150150
with:
151151
name: cdk-layer-artefact
152152
path: layer/cdk.out.zip

0 commit comments

Comments
 (0)