Credentials: reload from environment variables when expired
- Dominant language
- TypeScript
- Stars
- 2k
- Forks
- 807
- Avg merge
- 10h 12m
- Merged PRs (30d)
- 7
Description
**Describe the bug**
Error suggesting invalid profile on machine with existing credentials in env:variables
**To Reproduce**
After installing and ctrl+shift+p -> connect to AWS on a machine that already has a credentials details in env:variables with MFA enabled. Wait for the session token to expire. Create new credentials and store them in env:variables. Selecting either of env:variables and any other profiles returns an error "Credentials profile is invalid"
**Expected behavior**
AWS connects with env:varaiables when it is updated and valid, since Aggressive caching is fixed in version 1.6.0.
**Screenshots**

**Desktop (please complete the following information):**
- OS: Windows 10
- Visual Studio Code Version: 1.60.1
- AWS Toolkit Version: 1.29.0
Contributor guide
Research direction
Start by reproducing the expired-session scenario in the VS Code command that connects to AWS, using updated environment-variable credentials after the token expires. Trace how the selected environment credentials are loaded and cached; done means valid refreshed credentials connect successfully instead of producing “Credentials profile is invalid.”
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, typescript
- Domain
- authentication, cloud
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100