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
use amzn_codewhisperer_streaming_client::operation::generate_assistant_response::GenerateAssistantResponseError::ThrottlingErrorasOperationThrottlingError;
289
-
use amzn_codewhisperer_streaming_client::types::ThrottlingExceptionReason;
290
-
use amzn_codewhisperer_streaming_client::types::error::ThrottlingError;
291
-
292
288
let status_code = err.raw_response().map(|res| res.status().as_u16());
293
289
let is_quota_breach = status_code.is_some_and(|status| status == 429);
294
290
let is_context_window_overflow = err.as_service_error().is_some_and(|err| {
295
291
matches!(err, err if err.meta().code() == Some("ValidationException") && err.meta().message() == Some("Input is too long."))
0 commit comments