fix except 语句

This commit is contained in:
fangjf2001@aliyun.com 2025-03-23 10:38:04 +08:00
parent 3faae85713
commit f4a4998d9e

View file

@ -510,7 +510,7 @@ class ConnectionHandler:
opus_datas, duration = self.tts.audio_to_opus_data(tts_file)
else:
self.logger.bind(tag=TAG).error(f"TTS出错:文件不存在{tts_file}")
except asyncio.TimeoutError | TimeoutError:
except asyncio.TimeoutError:
self.logger.bind(tag=TAG).error("TTS超时")
except Exception as e:
self.logger.bind(tag=TAG).error(f"TTS出错: {e}")