From 701ec1e27e2214cdf438fddf16b956539b37f44a Mon Sep 17 00:00:00 2001 From: cybermaggedon Date: Wed, 29 Jan 2025 19:11:08 +0000 Subject: [PATCH] Fix startup error on import (#292) --- .../trustgraph/model/text_completion/bedrock/llm.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/trustgraph-bedrock/trustgraph/model/text_completion/bedrock/llm.py b/trustgraph-bedrock/trustgraph/model/text_completion/bedrock/llm.py index f87cf917..21c81fec 100755 --- a/trustgraph-bedrock/trustgraph/model/text_completion/bedrock/llm.py +++ b/trustgraph-bedrock/trustgraph/model/text_completion/bedrock/llm.py @@ -5,7 +5,6 @@ Input is prompt, output is response. Mistral is default. """ import boto3 -from botocore.errorfactory import ThrottlingException import json from prometheus_client import Histogram import os @@ -259,7 +258,7 @@ class Processor(ConsumerProducer): print("Done.", flush=True) - except ThrottlingException: + except self.bedrock.exceptions.ThrottlingException: print("Send rate limit response...", flush=True)