LiveTalking icon indicating copy to clipboard operation
LiveTalking copied to clipboard

豆包TTS报错

Open DESAKEY opened this issue 5 months ago • 2 comments

UnicodeDecodeError: 'utf-8' codec can't decode byte 0xf0 in position 1: invalid continuation byte

DESAKEY avatar Jul 07 '25 07:07 DESAKEY

ERROR:logger:doubao Traceback (most recent call last): File "D:\AIHuman\LiveTalking\LiveTalkingGitNew\LiveTalking\Miniconda3\lib\site-packages\websockets\legacy\protocol.py", line 963, in transfer_data message = await self.read_message() File "D:\AIHuman\LiveTalking\LiveTalkingGitNew\LiveTalking\Miniconda3\lib\site-packages\websockets\legacy\protocol.py", line 1048, in read_message return frame.data.decode("utf-8") if text else frame.data UnicodeDecodeError: 'utf-8' codec can't decode byte 0xf0 in position 1: invalid continuation byte

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "D:\AIHuman\LiveTalking\LiveTalkingGitNew\LiveTalking\ttsreal.py", line 581, in doubao_voice res = await ws.recv() File "D:\AIHuman\LiveTalking\LiveTalkingGitNew\LiveTalking\Miniconda3\lib\site-packages\websockets\legacy\protocol.py", line 568, in recv await self.ensure_open() File "D:\AIHuman\LiveTalking\LiveTalkingGitNew\LiveTalking\Miniconda3\lib\site-packages\websockets\legacy\protocol.py", line 948, in ensure_open raise self.connection_closed_exc() websockets.exceptions.ConnectionClosedError: sent 1007 (invalid frame payload data); no close frame received

DESAKEY avatar Jul 07 '25 07:07 DESAKEY

你是用http连接吗,是的话把ttsreal.py下doubaovoice方法里的submit_request_json["request"]["operation"] = "submit"中的submit改成query

RX365 avatar Aug 25 '25 03:08 RX365