Skip to content

Commit e457dff

Browse files
authored
Merge branch 'develop' into fix-8477
2 parents d54391a + 17114df commit e457dff

File tree

69 files changed

+2210
-1585
lines changed

Some content is hidden

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

69 files changed

+2210
-1585
lines changed

.github/workflows/automated-updates-to-sam-cli.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@ jobs:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- name: Checkout App Templates
17-
uses: actions/checkout@v5
17+
uses: actions/checkout@v6
1818
with:
1919
repository: aws/aws-sam-cli-app-templates
2020
path: aws-sam-cli-app-templates
2121

2222
- name: Checkout SAM CLI
23-
uses: actions/checkout@v5
23+
uses: actions/checkout@v6
2424
with:
2525
repository: aws/aws-sam-cli
2626
path: aws-sam-cli
@@ -59,15 +59,15 @@ jobs:
5959
runs-on: ubuntu-latest
6060
steps:
6161
- name: Checkout SAM
62-
uses: actions/checkout@v5
62+
uses: actions/checkout@v6
6363
with:
6464
repository: aws/serverless-application-model
6565
path: serverless-application-model
6666
ref: main
6767
fetch-depth: 0
6868

6969
- name: Checkout SAM CLI
70-
uses: actions/checkout@v5
70+
uses: actions/checkout@v6
7171
with:
7272
repository: aws/aws-sam-cli
7373
path: aws-sam-cli
@@ -110,15 +110,15 @@ jobs:
110110
runs-on: ubuntu-latest
111111
steps:
112112
- name: Checkout Lambda Builders
113-
uses: actions/checkout@v5
113+
uses: actions/checkout@v6
114114
with:
115115
repository: aws/aws-lambda-builders
116116
path: aws-lambda-builders
117117
ref: main
118118
fetch-depth: 0
119119

120120
- name: Checkout SAM CLI
121-
uses: actions/checkout@v5
121+
uses: actions/checkout@v6
122122
with:
123123
repository: aws/aws-sam-cli
124124
path: aws-sam-cli

.github/workflows/build.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ jobs:
6464
mkdir "D:\\Temp"
6565
echo "TEMP=D:\\Temp" >> $env:GITHUB_ENV
6666
if: ${{ matrix.os == 'windows-latest' }}
67-
- uses: actions/checkout@v5
67+
- uses: actions/checkout@v6
6868
- uses: actions/setup-python@v6
6969
with:
7070
python-version: ${{ matrix.python }}
@@ -79,7 +79,7 @@ jobs:
7979
contents: write
8080
runs-on: ubuntu-latest
8181
steps:
82-
- uses: actions/checkout@v5
82+
- uses: actions/checkout@v6
8383
- uses: actions/setup-python@v6
8484
name: Install Python 3.11
8585
with:
@@ -139,7 +139,7 @@ jobs:
139139
#- "traces"
140140
#- "validate"
141141
steps:
142-
- uses: actions/checkout@v5
142+
- uses: actions/checkout@v6
143143
- name: Set TEMP to D:/Temp
144144
run: |
145145
mkdir "D:\\Temp"
@@ -160,8 +160,7 @@ jobs:
160160
- uses: actions/setup-go@v6
161161
with:
162162
go-version: '1.19'
163-
# Pin to specific version until Lambda Builders support bundler 4.0.0
164-
- uses: ruby/setup-ruby@v1.268.0
163+
- uses: ruby/setup-ruby@v1
165164
with:
166165
ruby-version: "3.3"
167166
- uses: actions/setup-node@v6
@@ -176,6 +175,9 @@ jobs:
176175
17
177176
21
178177
25
178+
- uses: actions/setup-dotnet@v5
179+
with:
180+
dotnet-version: '10.0.x'
179181
# Install and configure Rust & Cargo Lambda
180182
- name: Install and configure Rust & Cargo Lambda
181183
if: ${{ matrix.os == 'ubuntu-latest' }}
@@ -231,7 +233,7 @@ jobs:
231233
params: "-n 4 tests/smoke tests/functional"
232234
env_vars: "third-third"
233235
steps:
234-
- uses: actions/checkout@v5
236+
- uses: actions/checkout@v6
235237
- name: Set TEMP to D:/Temp
236238
run: |
237239
mkdir "D:\\Temp"
@@ -261,7 +263,7 @@ jobs:
261263
- ubuntu-latest
262264
- windows-latest
263265
steps:
264-
- uses: actions/checkout@v5
266+
- uses: actions/checkout@v6
265267
- name: Set TEMP to D:/Temp
266268
run: |
267269
mkdir "D:\\Temp"

.github/workflows/codeql.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ jobs:
4242

4343
steps:
4444
- name: Checkout repository
45-
uses: actions/checkout@v5
45+
uses: actions/checkout@v6
4646

4747
# Initializes the CodeQL tools for scanning.
4848
- name: Initialize CodeQL

.github/workflows/integration-tests.yml

Lines changed: 42 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ env:
2424
CARGO_LAMBDA_VERSION: "v0.17.1"
2525
NOSE_PARAMETERIZED_NO_WARN: 1
2626
BY_CANARY: true
27-
UV_PYTHON: python3.9
27+
UV_PYTHON: python3.11
2828
CREDENTIAL_DISTRIBUTION_LAMBDA_ARN: ${{ secrets.CREDENTIAL_DISTRIBUTION_LAMBDA_ARN }}
2929
ACCOUNT_RESET_LAMBDA_ARN: ${{ secrets.ACCOUNT_RESET_LAMBDA_ARN }}
3030

@@ -74,7 +74,7 @@ jobs:
7474

7575
steps:
7676
- name: Checkout code
77-
uses: actions/checkout@v4
77+
uses: actions/checkout@v6
7878
with:
7979
# For scheduled runs, always use develop
8080
# For manual runs, use the branch from "Use workflow from" dropdown
@@ -139,7 +139,7 @@ jobs:
139139

140140
- name: Set up Go
141141
if: contains(fromJSON('["build-integ", "build-integ-java-python-provided", "build-integ-arm64"]'), matrix.test_suite) && matrix.container_runtime == 'no-container'
142-
uses: actions/setup-go@v5
142+
uses: actions/setup-go@v6
143143
with:
144144
go-version: '1.25'
145145

@@ -149,35 +149,35 @@ jobs:
149149
# Remove system Maven if it exists
150150
sudo apt-get remove -y maven || true
151151
152-
# Install Maven 3.9.11
153-
wget https://dlcdn.apache.org/maven/maven-3/3.9.11/binaries/apache-maven-3.9.11-bin.zip -P /tmp
152+
# Install Maven 3.9.12
153+
wget https://dlcdn.apache.org/maven/maven-3/3.9.12/binaries/apache-maven-3.9.12-bin.zip -P /tmp
154154
sudo unzip -d /opt/mvn /tmp/apache-maven-*.zip
155155
156156
# Install Gradle 9.2.0
157157
wget https://services.gradle.org/distributions/gradle-9.2.0-bin.zip -P /tmp
158158
sudo unzip -d /opt/gradle /tmp/gradle-*.zip
159159
160160
# Create symlinks to ensure our Maven is used
161-
sudo ln -sf /opt/mvn/apache-maven-3.9.11/bin/mvn /usr/local/bin/mvn
161+
sudo ln -sf /opt/mvn/apache-maven-3.9.12/bin/mvn /usr/local/bin/mvn
162162
sudo ln -sf /opt/gradle/gradle-9.2.0/bin/gradle /usr/local/bin/gradle
163163
164164
# Add to PATH (prepend to ensure our versions are used first)
165-
echo "/opt/mvn/apache-maven-3.9.11/bin" >> $GITHUB_PATH
165+
echo "/opt/mvn/apache-maven-3.9.12/bin" >> $GITHUB_PATH
166166
echo "/opt/gradle/gradle-9.2.0/bin" >> $GITHUB_PATH
167167
168168
# Set MAVEN_HOME
169-
echo "MAVEN_HOME=/opt/mvn/apache-maven-3.9.11" >> $GITHUB_ENV
169+
echo "MAVEN_HOME=/opt/mvn/apache-maven-3.9.12" >> $GITHUB_ENV
170170
171171
# Verify versions
172-
export PATH="/opt/mvn/apache-maven-3.9.11/bin:/opt/gradle/gradle-9.2.0/bin:$PATH"
172+
export PATH="/opt/mvn/apache-maven-3.9.12/bin:/opt/gradle/gradle-9.2.0/bin:$PATH"
173173
mvn --version
174174
gradle --version
175175
176-
- name: Install .NET 8 SDK
176+
- name: Install .NET 10 SDK
177177
if: contains(fromJSON('["build-integ-java-python-provided", "build-integ-dotnet-node-ruby", "build-integ-arm64"]'), matrix.test_suite) && matrix.container_runtime == 'no-container' || matrix.test_suite == 'other-and-e2e'
178178
uses: actions/setup-dotnet@v5
179179
with:
180-
dotnet-version: '8.0.x'
180+
dotnet-version: '10.0.x'
181181

182182
- name: Set up Ruby 3.3.7
183183
if: (contains(fromJSON('["build-integ","build-integ-dotnet-node-ruby", "build-integ-arm64"]'), matrix.test_suite) && matrix.container_runtime == 'no-container') || matrix.test_suite == 'other-and-e2e'
@@ -297,33 +297,52 @@ jobs:
297297
- name: Get testing resources and credentials
298298
run: |
299299
# Try with skip_role_deletion parameter first
300-
test_env_var=$(python3.9 tests/get_testing_resources.py skip_role_deletion)
300+
test_env_var=$(python3.11 tests/get_testing_resources.py skip_role_deletion)
301301
302302
if [ $? -ne 0 ]; then
303303
echo "First attempt with skip_role_deletion failed, trying without parameter..."
304-
test_env_var=$(python3.9 tests/get_testing_resources.py)
304+
test_env_var=$(python3.11 tests/get_testing_resources.py)
305305
306306
if [ $? -ne 0 ]; then
307307
echo "get_testing_resources failed. Failed to acquire credentials or test resources."
308308
exit 1
309309
fi
310310
fi
311311
312-
# Save current credentials for account reset later
312+
# Save current credentials for account reset later (mask them first)
313+
echo "::add-mask::$AWS_ACCESS_KEY_ID"
314+
echo "::add-mask::$AWS_SECRET_ACCESS_KEY"
315+
echo "::add-mask::$AWS_SESSION_TOKEN"
313316
echo "CI_ACCESS_ROLE_AWS_ACCESS_KEY_ID=$AWS_ACCESS_KEY_ID" >> $GITHUB_ENV
314317
echo "CI_ACCESS_ROLE_AWS_SECRET_ACCESS_KEY=$AWS_SECRET_ACCESS_KEY" >> $GITHUB_ENV
315318
echo "CI_ACCESS_ROLE_AWS_SESSION_TOKEN=$AWS_SESSION_TOKEN" >> $GITHUB_ENV
316319
317-
# Set test credentials
318-
echo "AWS_ACCESS_KEY_ID=$(echo "$test_env_var" | jq -j ".accessKeyID")" >> $GITHUB_ENV
319-
echo "AWS_SECRET_ACCESS_KEY=$(echo "$test_env_var" | jq -j ".secretAccessKey")" >> $GITHUB_ENV
320-
echo "AWS_SESSION_TOKEN=$(echo "$test_env_var" | jq -j ".sessionToken")" >> $GITHUB_ENV
321-
echo "TASK_TOKEN=$(echo "$test_env_var" | jq -j ".taskToken")" >> $GITHUB_ENV
320+
# Extract test credentials and mask them before setting as env vars
321+
TEST_ACCESS_KEY_ID=$(echo "$test_env_var" | jq -j ".accessKeyID")
322+
TEST_SECRET_ACCESS_KEY=$(echo "$test_env_var" | jq -j ".secretAccessKey")
323+
TEST_SESSION_TOKEN=$(echo "$test_env_var" | jq -j ".sessionToken")
324+
TEST_TASK_TOKEN=$(echo "$test_env_var" | jq -j ".taskToken")
325+
326+
# Mask sensitive credentials so they don't appear in logs
327+
echo "::add-mask::$TEST_ACCESS_KEY_ID"
328+
echo "::add-mask::$TEST_SECRET_ACCESS_KEY"
329+
echo "::add-mask::$TEST_SESSION_TOKEN"
330+
echo "::add-mask::$TEST_TASK_TOKEN"
331+
332+
# Set test credentials as environment variables
333+
echo "AWS_ACCESS_KEY_ID=$TEST_ACCESS_KEY_ID" >> $GITHUB_ENV
334+
echo "AWS_SECRET_ACCESS_KEY=$TEST_SECRET_ACCESS_KEY" >> $GITHUB_ENV
335+
echo "AWS_SESSION_TOKEN=$TEST_SESSION_TOKEN" >> $GITHUB_ENV
336+
echo "TASK_TOKEN=$TEST_TASK_TOKEN" >> $GITHUB_ENV
337+
338+
# Set other test resources (non-sensitive)
322339
echo "AWS_S3_TESTING=$(echo "$test_env_var" | jq -j ".TestBucketName")" >> $GITHUB_ENV
323340
echo "AWS_ECR_TESTING=$(echo "$test_env_var" | jq -j ".TestECRURI")" >> $GITHUB_ENV
324341
echo "AWS_KMS_KEY=$(echo "$test_env_var" | jq -j ".TestKMSKeyArn")" >> $GITHUB_ENV
325342
echo "AWS_SIGNING_PROFILE_NAME=$(echo "$test_env_var" | jq -j ".TestSigningProfileName")" >> $GITHUB_ENV
326343
echo "AWS_SIGNING_PROFILE_VERSION_ARN=$(echo "$test_env_var" | jq -j ".TestSigningProfileARN")" >> $GITHUB_ENV
344+
echo "LMI_SUBNET_ID=$(echo "$test_env_var" | jq -j ".LMISubnetId")" >> $GITHUB_ENV
345+
echo "LMI_SECURITY_GROUP_ID=$(echo "$test_env_var" | jq -j ".LMISecurityGroupId")" >> $GITHUB_ENV
327346
328347
- name: Login to Public ECR
329348
if: matrix.container_runtime != 'no-container' && env.BY_CANARY == 'true'
@@ -368,13 +387,13 @@ jobs:
368387
pytest -vv -n 2 --reruns 3 tests/integration/buildcmd/test_build_cmd_arm64.py -m 'java' -k "${CONTAINER_FILTER}" --json-report --json-report-file=TEST_REPORT-integration-buildcmd-arm64-java-${{ matrix.container_runtime }}.json
369388
;;
370389
"terraform-build")
371-
pytest -vv -n 4 --reruns 4 tests/integration/buildcmd/test_build_terraform_applications.py tests/integration/buildcmd/test_build_terraform_applications_other_cases.py --json-report --json-report-file=TEST_REPORT-integration-terraform-${{ matrix.container_runtime }}.json
390+
pytest -vv -n 4 --reruns 3 tests/integration/buildcmd/test_build_terraform_applications.py tests/integration/buildcmd/test_build_terraform_applications_other_cases.py --json-report --json-report-file=TEST_REPORT-integration-terraform-${{ matrix.container_runtime }}.json
372391
;;
373392
"package-delete-deploy")
374393
pytest -vv tests/integration/package tests/integration/delete tests/integration/deploy --dist=loadgroup -n 6 --reruns 4 --json-report --json-report-file=TEST_REPORT-integration-package-delete-deploy-${{ matrix.container_runtime }}.json
375394
;;
376395
"sync")
377-
pytest -vv tests/integration/sync -n 6 --reruns 3 --dist loadscope --json-report --json-report-file=TEST_REPORT-integration-sync-${{ matrix.container_runtime }}.json
396+
pytest -vv tests/integration/sync -n 4 --reruns 3 --dist loadscope --json-report --json-report-file=TEST_REPORT-integration-sync-${{ matrix.container_runtime }}.json
378397
;;
379398
"local-invoke")
380399
pytest -vv --reruns 3 tests/integration/local/invoke tests/integration/local/generate_event --ignore tests/integration/local/invoke/test_invoke_durable.py --json-report --json-report-file=TEST_REPORT-integration-local-invoke-${{ matrix.container_runtime }}.json
@@ -389,14 +408,13 @@ jobs:
389408
pytest -vv --reruns 3 tests/integration/local/invoke/test_invoke_durable.py tests/integration/local/start_api/test_start_api_durable.py tests/integration/local/start_lambda/test_start_lambda_durable.py tests/integration/local/callback/test_callback.py tests/integration/local/execution/test_execution.py --json-report --json-report-file=TEST_REPORT-integration-durable-functions-${{ matrix.container_runtime }}.json
390409
;;
391410
"other-and-e2e")
392-
pytest -vv -n 4 --reruns 4 --dist loadgroup tests/integration tests/end_to_end --ignore=tests/integration/buildcmd --ignore=tests/integration/delete --ignore=tests/integration/deploy --ignore=tests/integration/package --ignore=tests/integration/sync --ignore=tests/integration/local --json-report --json-report-file=TEST_REPORT-integration-others-${{ matrix.container_runtime }}.json
393-
pytest -vv --reruns 3 tests/regression --json-report --json-report-file=TEST_REPORT-regression-${{ matrix.container_runtime }}.json
411+
pytest -vv -n 4 --reruns 3 --dist loadgroup tests/integration tests/end_to_end tests/regression --ignore=tests/integration/buildcmd --ignore=tests/integration/delete --ignore=tests/integration/deploy --ignore=tests/integration/package --ignore=tests/integration/sync --ignore=tests/integration/local --json-report --json-report-file=TEST_REPORT-integration-others-${{ matrix.container_runtime }}.json
394412
;;
395413
esac
396414
397415
- name: Upload test results
398416
if: always()
399-
uses: actions/upload-artifact@v5
417+
uses: actions/upload-artifact@v6
400418
with:
401419
name: test-results-${{ matrix.test_suite }}-${{ matrix.container_runtime }}
402420
path: TEST_REPORT-*.json

.github/workflows/update-reproducibles.yml

Lines changed: 9 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -15,32 +15,23 @@ jobs:
1515
pull-requests: write
1616
contents: write
1717
if: github.repository_owner == 'aws'
18-
strategy:
19-
matrix:
20-
include:
21-
- os: ubuntu-latest
22-
python: 3.11
23-
target: update-reproducible-linux-reqs
24-
- os: macos-latest
25-
python: 3.11
26-
target: update-reproducible-mac-reqs
27-
- os: windows-latest
28-
python: 3.12
29-
target: update-reproducible-win-reqs
30-
max-parallel: 1
31-
runs-on: ${{ matrix.os }}
18+
runs-on: ubuntu-latest
3219
steps:
33-
- uses: actions/checkout@v5
20+
- uses: actions/checkout@v6
3421
with:
3522
ref: ${{ github.head_ref }}
3623
- uses: actions/setup-python@v6
3724
with:
38-
python-version: ${{ matrix.python }}
39-
- run: make ${{ matrix.target }}
25+
python-version: "3.11"
26+
- name: Install uv
27+
uses: astral-sh/setup-uv@v5
28+
- name: Update all reproducible requirements
29+
run: make update-reproducible-reqs-uv
4030
- name: Push changes
4131
run: |
4232
git config --global user.email "action@github.com"
4333
git config --global user.name "GitHub Action"
4434
git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}
45-
git commit -am "Update reproducibles: ${{ matrix.target }}" || echo "nothing to commit"
35+
git add requirements/reproducible-*.txt
36+
git commit -m "Update reproducible requirements" || echo "nothing to commit"
4637
git push

.github/workflows/validate_pyinstaller.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
strategy:
1717
fail-fast: false
1818
steps:
19-
- uses: actions/checkout@v5
19+
- uses: actions/checkout@v6
2020
- name: Make installer script executable
2121
run: chmod +x ./installer/pyinstaller/build-linux.sh
2222
- name: Build PyInstaller in manylinux container
@@ -32,7 +32,7 @@ jobs:
3232
sudo ./sam-installation/install
3333
sam-beta --version
3434
./tests/sanity-check.sh
35-
- uses: actions/upload-artifact@v5
35+
- uses: actions/upload-artifact@v6
3636
with:
3737
name: pyinstaller-linux-zip
3838
path: .build/output/aws-sam-cli-linux-x86_64.zip
@@ -45,7 +45,7 @@ jobs:
4545
strategy:
4646
fail-fast: false
4747
steps:
48-
- uses: actions/checkout@v5
48+
- uses: actions/checkout@v6
4949
- uses: actions/setup-python@v6
5050
with:
5151
python-version: "3.11"
@@ -61,7 +61,7 @@ jobs:
6161
sudo ./sam-installation/install
6262
sam-beta --version
6363
./tests/sanity-check.sh
64-
- uses: actions/upload-artifact@v5
64+
- uses: actions/upload-artifact@v6
6565
with:
6666
name: pyinstaller-macos-zip
6767
path: .build/output/aws-sam-cli-macos-x86_64.zip

Makefile

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,3 +87,10 @@ update-reproducible-win-reqs:
8787

8888

8989
update-reproducible-reqs: update-reproducible-linux-reqs update-reproducible-mac-reqs
90+
91+
# Update all reproducible requirements using uv (can run from any platform)
92+
update-reproducible-reqs-uv:
93+
@command -v uv >/dev/null 2>&1 || pip install uv
94+
uv pip compile setup.py --generate-hashes --output-file requirements/reproducible-linux.txt --python-platform linux --python-version 3.11 --no-cache --no-strip-extras
95+
uv pip compile setup.py --generate-hashes --output-file requirements/reproducible-mac.txt --python-platform macos --python-version 3.11 --no-cache --no-strip-extras
96+
uv pip compile setup.py --generate-hashes --output-file requirements/reproducible-win.txt --python-platform windows --python-version 3.12 --no-cache --no-strip-extras

0 commit comments

Comments
 (0)