Browse Source

feat(azure_voice.py): improve error logging in textToVoice method

master
lanvent 1 year ago
parent
commit
a83e5a9b65
1 changed files with 5 additions and 1 deletions
  1. +5
    -1
      voice/azure/azure_voice.py

+ 5
- 1
voice/azure/azure_voice.py View File

@@ -83,6 +83,10 @@ class AzureVoice(Voice):
) )
reply = Reply(ReplyType.VOICE, fileName) reply = Reply(ReplyType.VOICE, fileName)
else: else:
logger.error("[Azure] textToVoice error, result={}".format(result))
logger.error(
"[Azure] textToVoice error, result={}, canceldetails={}".format(
result, result.cancellation_details
)
)
reply = Reply(ReplyType.ERROR, "抱歉,语音合成失败") reply = Reply(ReplyType.ERROR, "抱歉,语音合成失败")
return reply return reply

Loading…
Cancel
Save