mirror of
https://github.com/danswer-ai/danswer.git
synced 2025-06-25 07:21:00 +02:00
continue on internal error (#3728)
This commit is contained in:
parent
8d62b992ef
commit
42d6d935ae
@ -104,8 +104,11 @@ def make_slack_api_rate_limited(
|
|||||||
f"Slack call rate limited, retrying after {retry_after} seconds. Exception: {e}"
|
f"Slack call rate limited, retrying after {retry_after} seconds. Exception: {e}"
|
||||||
)
|
)
|
||||||
time.sleep(retry_after)
|
time.sleep(retry_after)
|
||||||
elif error in ["already_reacted", "no_reaction"]:
|
elif error in ["already_reacted", "no_reaction", "internal_error"]:
|
||||||
# The response isn't used for reactions, this is basically just a pass
|
# Log internal_error and return the response instead of failing
|
||||||
|
logger.warning(
|
||||||
|
f"Slack call encountered '{error}', skipping and continuing..."
|
||||||
|
)
|
||||||
return e.response
|
return e.response
|
||||||
else:
|
else:
|
||||||
# Raise the error for non-transient errors
|
# Raise the error for non-transient errors
|
||||||
|
Loading…
x
Reference in New Issue
Block a user