[BUG] credential_process fails on second API call in session (2.1.79 regression)

Resolved 💬 7 comments Opened Mar 19, 2026 by RH-Matt Closed Mar 20, 2026

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?

The first Bedrock API call in a session succeeds (e.g., simple query with no tool use). All subsequent API calls fail immediately (~6-15ms) with "Could not load credentials from any providers" — even though credential_process continues to run successfully when invoked directly.
Evidence:

  • Debug logs show credential_process script executes and returns valid credentials every time
  • First API call: succeeds, takes ~244ms (credential resolution time)
  • Second API call: fails in 6-15ms (cached failure, no subprocess spawn)
  • The fast failure time indicates credentials are cached as "failed" after the first tool execution

What Should Happen?

When using credential_process for Bedrock authentication, all API calls within a session should resolve credentials successfully. The second and subsequent API calls (e.g., after tool execution) should invoke credential_process the same way the first call does, rather than using a cached failure state. Tool-use queries should work identically to simple queries.

Error Messages/Logs

First API call (succeeds):
2026-03-19T15:30:10.711Z [DEBUG] [API:request] Creating client
2026-03-19T15:30:10.712Z [DEBUG] [API:auth] OAuth token check complete
2026-03-19T15:29:56.044Z [DEBUG] Stream started - received first chunk                                                                    

Second API call after tool execution (fails immediately):
2026-03-19T15:30:10.711Z [DEBUG] [API:request] Creating client
2026-03-19T15:30:10.727Z [ERROR] API error (attempt 1/11): Could not load credentials from any providers
Timing evidence showing cached failure (6ms vs 244ms for fresh credential resolution):
- First call: ~244ms (time to spawn python subprocess and get credentials)
- Second call: 6-15ms (no subprocess, returns cached failure)
Credential process debug logs prove the script works when called:
2026-03-19T15:29:37.716750+00:00 pid=29640 INVOKED
2026-03-19T15:29:40.480753+00:00 pid=29640 SUCCESS expiry=2026-03-19T16:00:02Z

The credential_process executes successfully throughout the session, but the AWS SDK client in claude.exe stops invoking it after the first API call.

Steps to Reproduce

Reproduction: Configure credential_process in AWS config, make a query requiring tool use (e.g., "List files"). First API call succeeds, second fails after tool execution.

Claude Model

Not sure / Multiple models

Is this a regression?

Yes, this worked in a previous version

Last Working Version

Claude Code Extension: 2.1.77 (win32-x64)

Claude Code Version

2.1.79 (Claude Code)

Platform

AWS Bedrock

Operating System

Windows

Terminal/Shell

VS Code integrated terminal

Additional Information

Claude Code can be used from the terminal and the credential_process authentication functions as expected. This is only an issue in the VSCode extension for Claude Code and only in the most recent update that came down on 18-March-26.

View original on GitHub ↗

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