[BUG] Bedrock configuration from env variables not consistently updating in Claude VSCode extension

Resolved 💬 3 comments Opened Sep 12, 2025 by aichohan Closed Sep 15, 2025

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

When using AWS Bedrock credentials from environment variables, the Claude VSCode extension sometimes fails to load updated values. On my Mac terminal, running env shows the correct variables, and running claude reflects changes immediately (for example, correctly showing prompt caching as disabled). However, the VSCode extension often continues using stale or expired values, which breaks my workflow if an API key has rotated. Restarting VSCode or reloading the extension does not consistently fix the issue, though it occasionally resolves on its own.

What Should Happen?

The Claude VSCode extension should always reload and respect the current environment variables, matching the behavior of the CLI. Updated AWS Bedrock credentials (e.g., after an API key rotation) should be picked up immediately without requiring manual restarts, ensuring workflows do not break.

Error Messages/Logs

Steps to Reproduce

1 . Set or update AWS Bedrock environment variables in your shell (e.g., export new AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN).

  1. In Terminal, run env to confirm values are correct.
  1. Run claude in Terminal → observe it picks up the updated values (e.g., prompt caching disabled).
  1. Open VS Code and use the Claude extension → observe it still uses old/stale variables, sometimes breaking if credentials expired.

Claude Model

None

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

1.0.112

Platform

AWS Bedrock

Operating System

macOS

Terminal/Shell

VS Code integrated terminal

Additional Information

_No response_

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗