Skip to content

fix(amplify-e2e-tests): handle InvalidClientTokenId in getAmplifyApps opt-in region cleanup#3512

Merged
svidgen merged 1 commit into
release-api-plugin-stablefrom
fix/cleanup-e2e-invalidclienttokenid-relstable
Jul 9, 2026
Merged

fix(amplify-e2e-tests): handle InvalidClientTokenId in getAmplifyApps opt-in region cleanup#3512
svidgen merged 1 commit into
release-api-plugin-stablefrom
fix/cleanup-e2e-invalidclienttokenid-relstable

Conversation

@sarayev

@sarayev sarayev commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Description

Opt-in regions (ap-east-1, eu-south-1) are not enabled on the e2e test accounts. When getAmplifyApps calls the Amplify client in those regions, it throws InvalidClientTokenId, which currently propagates out of the cleanup script → process.exit(1) → fails the cleanup_e2e_resources shard.

This mirrors the existing guard in getStacks() by also skipping on InvalidClientTokenId (in addition to the existing UnrecognizedClientException), logging and continuing rather than failing.

This is a backport of the fix already on main (#3304) to the release-api-plugin-stable branch.

Scope

  • e2e-cleanup only, not customer-facing
  • Exactly one file, one logical change

… opt-in region cleanup

Opt-in regions (ap-east-1/eu-south-1) are not enabled on test accounts, causing getAmplifyApps to throw InvalidClientTokenId which propagates to process.exit(1) and fails the cleanup_e2e_resources shard. Mirror the existing getStacks() guard by also skipping on InvalidClientTokenId. Backport of the fix already on main (#3304) to release-api-plugin-stable. e2e-cleanup only, not customer-facing.
@sarayev sarayev requested a review from a team as a code owner July 9, 2026 15:38
@svidgen svidgen merged commit 5d1cd14 into release-api-plugin-stable Jul 9, 2026
6 checks passed
@svidgen svidgen deleted the fix/cleanup-e2e-invalidclienttokenid-relstable branch July 9, 2026 15:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants