You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
C:\Anaconda3\python.exe D:/AnyCode/python/Robot3D/BaiduVoiceAPI_Python-master/baidu.py
Traceback (most recent call last):
File "D:/AnyCode/python/Robot3D/BaiduVoiceAPI_Python-master/baidu.py", line 463, in
t = TTS()
File "D:/AnyCode/python/Robot3D/BaiduVoiceAPI_Python-master/baidu.py", line 149, in init
self.token = GetToken(self.app_key, self.secret_key)
File "D:/AnyCode/python/Robot3D/BaiduVoiceAPI_Python-master/baidu.py", line 26, in GetToken
response = urlopen("https://openapi.baidu.com/oauth/2.0/token", data=urlencode(data))
File "C:\Anaconda3\lib\urllib\request.py", line 161, in urlopen
return opener.open(url, data, timeout)
File "C:\Anaconda3\lib\urllib\request.py", line 461, in open
req = meth(req)
File "C:\Anaconda3\lib\urllib\request.py", line 1112, in do_request_
raise TypeError(msg)
TypeError: POST data should be bytes or an iterable of bytes. It cannot be of type str.
Process finished with exit code 1
The text was updated successfully, but these errors were encountered:
C:\Anaconda3\python.exe D:/AnyCode/python/Robot3D/BaiduVoiceAPI_Python-master/baidu.py
Traceback (most recent call last):
File "D:/AnyCode/python/Robot3D/BaiduVoiceAPI_Python-master/baidu.py", line 463, in
t = TTS()
File "D:/AnyCode/python/Robot3D/BaiduVoiceAPI_Python-master/baidu.py", line 149, in init
self.token = GetToken(self.app_key, self.secret_key)
File "D:/AnyCode/python/Robot3D/BaiduVoiceAPI_Python-master/baidu.py", line 26, in GetToken
response = urlopen("https://openapi.baidu.com/oauth/2.0/token", data=urlencode(data))
File "C:\Anaconda3\lib\urllib\request.py", line 161, in urlopen
return opener.open(url, data, timeout)
File "C:\Anaconda3\lib\urllib\request.py", line 461, in open
req = meth(req)
File "C:\Anaconda3\lib\urllib\request.py", line 1112, in do_request_
raise TypeError(msg)
TypeError: POST data should be bytes or an iterable of bytes. It cannot be of type str.
Process finished with exit code 1
The text was updated successfully, but these errors were encountered: