requests.exceptions.ConnectionError: ('Connection aborted.', error("(32, 'EPIPE')",))
Closed this issue · 1 comments
nickpettican commented
Hi @ParhamP, thanks for the script. I've come across an issue, which I raised on SimpleAudioIndexer's end: aalireza/SimpleAudioIndexer#8; but I thought you should be aware of it too:
File "/Users/nickpettican/miniconda3/envs/py27/lib/python2.7/site-packages/SimpleAudioIndexer/__init__.py", line 1108, in index_audio
self._index_audio_ibm(*args, **kwargs)
File "/Users/nickpettican/miniconda3/envs/py27/lib/python2.7/site-packages/SimpleAudioIndexer/__init__.py", line 944, in _index_audio_ibm
params=params)
File "/Users/nickpettican/miniconda3/envs/py27/lib/python2.7/site-packages/requests/api.py", line 112, in post
return request('post', url, data=data, json=json, **kwargs)
File "/Users/nickpettican/miniconda3/envs/py27/lib/python2.7/site-packages/requests/api.py", line 58, in request
return session.request(method=method, url=url, **kwargs)
File "/Users/nickpettican/miniconda3/envs/py27/lib/python2.7/site-packages/requests/sessions.py", line 508, in request
resp = self.send(prep, **send_kwargs)
File "/Users/nickpettican/miniconda3/envs/py27/lib/python2.7/site-packages/requests/sessions.py", line 618, in send
r = adapter.send(request, **kwargs)
File "/Users/nickpettican/miniconda3/envs/py27/lib/python2.7/site-packages/requests/adapters.py", line 490, in send
raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', error("(32, 'EPIPE')",))
It seems to be happening in the post request:
response = requests.post(
url=("https://stream.watsonplatform.net/"
"speech-to-text/api/v1/recognize"),
auth=(self.get_username_ibm(), self.get_password_ibm()),
headers={'content-type': 'audio/wav'},
data=f.read(),
params=params)
Any ideas?
nickpettican commented
Solved - I was using the IBM credentials instead of the ones provided by the project.
See aalireza/SimpleAudioIndexer#8 for more info.
Thanks!