refine code: use handle_exception function instead of in-function duplicate code frags

This commit is contained in:
geekan 2023-12-19 16:16:52 +08:00
parent d3c135edff
commit f1c6a7ebfb
12 changed files with 159 additions and 130 deletions

View file

@ -137,6 +137,7 @@ class Config(metaclass=Singleton):
continue
configs.update(yaml_data)
OPTIONS.set(configs)
logger.info(f"Default OpenAI API Model: {self.openai_api_model}")
@staticmethod
def _get(*args, **kwargs):