Skip to content

Commit

Permalink
bump to 3.4.4 software version
Browse files Browse the repository at this point in the history
added two new openai exceptions to
  • Loading branch information
Bikatr7 committed Apr 15, 2024
1 parent 5b4aff8 commit c3bbcb5
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions models/kijiku.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
from modules.common.file_ensurer import FileEnsurer
from modules.common.logger import Logger
from modules.common.toolkit import Toolkit
from modules.common.exceptions import AuthenticationError, MaxBatchDurationExceededException, AuthenticationError, InternalServerError, RateLimitError, APITimeoutError, GoogleAuthError
from modules.common.exceptions import AuthenticationError, MaxBatchDurationExceededException, AuthenticationError, InternalServerError, RateLimitError, APITimeoutError, GoogleAuthError, APIStatusError, APIConnectionError
from modules.common.decorators import permission_error_decorator

##-------------------start-of-Kijiku--------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Expand Down Expand Up @@ -427,7 +427,7 @@ async def commence_translation(is_webgui:bool=False) -> None:


if(Kijiku.LLM_TYPE == "openai"):
Kijiku.decorator_to_use = backoff.on_exception(backoff.expo, max_time=lambda: Kijiku.get_max_batch_duration(), exception=(AuthenticationError, InternalServerError, RateLimitError, APITimeoutError), on_backoff=lambda details: Kijiku.log_retry(details), on_giveup=lambda details: Kijiku.log_failure(details), raise_on_giveup=False)
Kijiku.decorator_to_use = backoff.on_exception(backoff.expo, max_time=lambda: Kijiku.get_max_batch_duration(), exception=(AuthenticationError, InternalServerError, RateLimitError, APITimeoutError, APIConnectionError, APIStatusError), on_backoff=lambda details: Kijiku.log_retry(details), on_giveup=lambda details: Kijiku.log_failure(details), raise_on_giveup=False)

else:
Kijiku.decorator_to_use = backoff.on_exception(backoff.expo, max_time=lambda: Kijiku.get_max_batch_duration(), exception=(Exception), on_backoff=lambda details: Kijiku.log_retry(details), on_giveup=lambda details: Kijiku.log_failure(details), raise_on_giveup=False)
Expand Down
2 changes: 1 addition & 1 deletion modules/common/exceptions.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## third-party libraries
## for importing, other scripts will use from common.exceptions instead of from the third-party libraries themselves
from easytl import AuthenticationError, InternalServerError, RateLimitError, APITimeoutError
from easytl import AuthenticationError, InternalServerError, RateLimitError, APITimeoutError, APIConnectionError, APIStatusError
from easytl import AuthorizationException, QuotaExceededException
from easytl import GoogleAuthError

Expand Down
2 changes: 1 addition & 1 deletion modules/common/toolkit.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class Toolkit():
"""

CURRENT_VERSION = "v3.4.3"
CURRENT_VERSION = "v3.4.4"

##-------------------start-of-clear_console()---------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Expand Down

0 comments on commit c3bbcb5

Please sign in to comment.