You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Errors in the Custom Resource Lambda provider function for Bedrock agents don't seem to get surfaced properly at the CDK console, I think because a Future is being embedded into the error message instead of the result of the future.
For example, if I try to create an agent with a model that isn't yet one of the static members:
I see the following deployment error: ❌ Deployment failed: Error: The stack named ______ failed to deploy: UPDATE_ROLLBACK_COMPLETE: Received response status [FAILED] from custom resource. Message returned: Error: RetryError[<Future at 0x7f5b68612840 state=finished raised AWSRetryableError>]
Expected Behavior
If I go to the AWS console and look at the CR Lambda log, I can find the error I'm looking for:
It looks like the final error handling logic is embedding the Future object into the message instead of the result, and we should be seeing the informative message Foundation model is null or not supported, try providing [anthropic.claude-v1, anthropic.claude-v2, anthropic.claude-instant-v1, anthropic.claude-v2:1, amazon.titan-text-premier-v1:0, anthropic.claude-3-sonnet-20240229-v1:0, anthropic.claude-3-haiku-20240307-v1:0] at the CDK console instead.
Current Behavior
Error cause is hidden, Future object is printed in message instead of error message.
Reproduction Steps
Try deploying an Agent with an unsupported model, e.g.:
I also saw the same thing happen when the model instruction was too many characters.
Possible Solution
The error message is showing RetryError[<Future at 0x7f5b68612840 state=finished raised AWSRetryableError>], so it seems like the result of the Future object needs to be put into the message instead of the object itself (e.g. future.result() instead of future).
Additional Information/Context
No response
CDK CLI Version
2.138.0
Framework Version
cdklabs.generative-ai-cdk-constructs==0.1.124
Node.js Version
v20.11.0
OS
OSX
Language
Python
Language Version
Python 3.11
Region experiencing the issue
us-east-1
Code modification
No
Other information
No response
Service quota
I have reviewed the service quotas for this construct
The text was updated successfully, but these errors were encountered:
Describe the bug
Errors in the Custom Resource Lambda provider function for Bedrock agents don't seem to get surfaced properly at the CDK console, I think because a
Future
is being embedded into the error message instead of the result of the future.For example, if I try to create an agent with a model that isn't yet one of the static members:
I see the following deployment error:
❌ Deployment failed: Error: The stack named ______ failed to deploy: UPDATE_ROLLBACK_COMPLETE: Received response status [FAILED] from custom resource. Message returned: Error: RetryError[<Future at 0x7f5b68612840 state=finished raised AWSRetryableError>]
Expected Behavior
If I go to the AWS console and look at the CR Lambda log, I can find the error I'm looking for:
It looks like the final error handling logic is embedding the
Future
object into the message instead of the result, and we should be seeing the informative messageFoundation model is null or not supported, try providing [anthropic.claude-v1, anthropic.claude-v2, anthropic.claude-instant-v1, anthropic.claude-v2:1, amazon.titan-text-premier-v1:0, anthropic.claude-3-sonnet-20240229-v1:0, anthropic.claude-3-haiku-20240307-v1:0]
at the CDK console instead.Current Behavior
Error cause is hidden,
Future
object is printed in message instead of error message.Reproduction Steps
Try deploying an Agent with an unsupported model, e.g.:
I also saw the same thing happen when the model instruction was too many characters.
Possible Solution
The error message is showing
RetryError[<Future at 0x7f5b68612840 state=finished raised AWSRetryableError>]
, so it seems like the result of theFuture
object needs to be put into the message instead of the object itself (e.g.future.result()
instead offuture
).Additional Information/Context
No response
CDK CLI Version
2.138.0
Framework Version
cdklabs.generative-ai-cdk-constructs==0.1.124
Node.js Version
v20.11.0
OS
OSX
Language
Python
Language Version
Python 3.11
Region experiencing the issue
us-east-1
Code modification
No
Other information
No response
Service quota
The text was updated successfully, but these errors were encountered: