[bug] updating bedrock js instrumentation fails tests
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › InvokeModelWithResponseStream › Error Handling › should handle large payloads and timeouts
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › InvokeModelWithResponseStream › Edge Cases › should propagate OpenInference context attributes
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › InvokeModelWithResponseStream › Edge Cases › should handle non-Anthropic models via Bedrock
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › InvokeModelWithResponseStream › Cross-Provider Streaming Models › should handle Amazon Titan streaming responses with usage tracking
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › InvokeModelWithResponseStream › Cross-Provider Streaming Models › should handle Meta Llama streaming responses with proper token tracking
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › InvokeModelWithResponseStream › Cross-Provider Streaming Models › should handle Amazon Nova streaming responses with comprehensive validation
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Basic Functionality › should handle basic Converse API calls
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Basic Functionality › should handle basic converse stream responses
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Core Functionality › should handle streaming tool calls and responses
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Core Functionality › should handle multi-modal content in streaming responses
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Error Handling › should handle streaming API errors gracefully
expect(received).toBe(expected) // Object.is equality
Expected: 400
Received: 403
1857 | thrownError.$response?.statusCode ||
1858 | thrownError.$metadata?.httpStatusCode,
> 1859 | ).toBe(400);
| ^
1860 | expect(thrownError.message).toContain("model identifier is invalid");
1861 |
1862 | // Verify span was created and marked as error
at test/instrumentation.test.ts:1859:13
at Generator.throw (<anonymous>)
at rejected (test/instrumentation.test.ts:6:65)
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Error Handling › should handle large payloads and edge cases in streaming
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Configuration & Context › should handle system prompts with streaming responses
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Configuration & Context › should propagate context attributes in streaming
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Cross-Provider Streaming Models › should handle Meta Llama models with streaming
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Cross-Provider Streaming Models › should handle Mistral models with streaming
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Cross-Provider Streaming Models › should handle Amazon Titan models with streaming
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Cross-Provider Streaming Models › should handle Amazon Nova models with streaming
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Cross-Provider Streaming Models › should handle Cohere Command models with streaming
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › ConverseStream Functionality › Cross-Provider Streaming Models › should handle AI21 Jamba models with streaming
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › System Prompts › should handle single system prompt in Converse API
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › System Prompts › should handle multiple system prompts concatenation in Converse API
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Configuration › should handle inference config in Converse API
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Multi-Turn Conversations › should handle two-turn conversation with proper message indexing
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Multi-Turn Conversations › should handle system prompt with multi-turn conversation
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Multi-Modal Content › should handle text plus image content with detailed structure
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Multi-Modal Content › should handle different image formats with correct MIME types
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Cross-Vendor Models › should handle Mistral models
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Cross-Vendor Models › should handle Meta LLaMA models
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Error Handling › should handle missing token counts via converse
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Error Handling › should handle empty/minimal response
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Tool Configuration › should handle tool configuration
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Tool Configuration › should handle tool response processing
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Context Attributes › should handle context attributes with Converse
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation › Converse API › Context Attributes › should comprehensively test all token count types
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation - custom tracing › BedrockInstrumentation with custom TracerProvider passed in › should use the provided tracer provider instead of the global one
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation - custom tracing › BedrockInstrumentation with custom TracerProvider set › should use the provided tracer provider instead of the global one
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
● BedrockInstrumentation - custom tracing › BedrockInstrumentation with custom TracerProvider set via registerInstrumentations › should use the provided tracer provider instead of the global one
UnrecognizedClientException: The security token included in the request is invalid.
at throwDefaultError (../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:288:22)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/smithy-client/dist-cjs/index.js:297:9
at de_CommandError (../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/client-bedrock-runtime/dist-cjs/index.js:1646:20)
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-serde/dist-cjs/index.js:8:24
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/core/dist-cjs/index.js:121:20
at ../../node_modules/.pnpm/@[email protected]/node_modules/@smithy/middleware-retry/dist-cjs/index.js:254:46
at ../../node_modules/.pnpm/@[email protected]/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js:5:26
this relates to how aws-bedrock-runtime now checks credentials now. I had to pin the version but this will emerge if you unpin.
You're right—recent versions of aws-bedrock-runtime have stricter credential validation, which is why tests fail with UnrecognizedClientException unless valid AWS credentials are present or properly mocked. Pinning the version is a temporary workaround; if you unpin, these failures will recur unless the test setup is updated to handle credentials more robustly (for example, by mocking AWS SDK calls or providing dummy credentials via environment variables) source. There aren't any existing tickets or docs in OpenInference that address this directly, so future upgrades will require changes to how credentials are managed in tests.
To reply, just mention @dosu.
How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other