Skip to content

fix awscli patch for new create_nested_client, introduce bats tests #93

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

Merged
merged 2 commits into from
Aug 5, 2025

Conversation

alexrashed
Copy link
Member

@alexrashed alexrashed commented Aug 4, 2025

Motivation

awscli version 1.41.9 comes with aws/aws-cli#9602, which changes the way the AWS client is created. This conflicts with our patch for Cloudformation (modifying the S3 endpoint URL).
This PR fixes this, and also introduces a proper testing framework (bats).
Fixes #91.

Changes

  • Introduces a new test pipeline which runs certain smoke tests using bats.
  • Fixes the patch of the create_client function for awslocal cloudformation package and awslocal cloudformation deploy.
    • Instead of using a fixed position in the outer frames, we now backtrack to see if we can find the right frame in the whole set of frames. This approach is compatible with the versions before 1.41.9, as well as the versions since then.

Copy link

github-actions bot commented Aug 4, 2025

Smoke Tests

 6 files  12 suites   3m 22s ⏱️
 4 tests  4 ✅ 0 💤 0 ❌
24 runs  24 ✅ 0 💤 0 ❌

Results for commit e066dce.

♻️ This comment has been updated with latest results.

@alexrashed alexrashed force-pushed the fix-s3-patch branch 4 times, most recently from dd588a6 to 63b9bb6 Compare August 4, 2025 13:35
@alexrashed alexrashed marked this pull request as ready for review August 4, 2025 13:53
@alexrashed alexrashed changed the title fix awscli patch for new create_nested_client fix awscli patch for new create_nested_client, introduce bats tests Aug 4, 2025
Copy link
Member

@dominikschubert dominikschubert left a comment

Choose a reason for hiding this comment

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

Thanks for jumping on this. I hope we can continue reducing our dependency on awslocal in the future but that's a great patch for now 👍

Appreciate the evolution of the CI workflow and you extending the test matrix to make sure we cover a version before the boundary version of this specific issue 🙏

@alexrashed alexrashed merged commit 9446919 into master Aug 5, 2025
8 checks passed
@alexrashed alexrashed deleted the fix-s3-patch branch August 5, 2025 11:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

cfn deploy & package break with aws-cli version 1.41.9
2 participants