I’ve managed to get a fairly reliable client-side streamer running that will manage local disconnects. But I’m now getting intermittent errors which seem to be server-side (i.e. Twitter-initiated) disconnects. The following is typical:
File "/usr/local/lib/python2.7/dist-packages/twython/endpoints.py", line 114, in update_status
return self.post('statuses/update', params=params)
File "/usr/local/lib/python2.7/dist-packages/twython/api.py", line 268, in post
return self.request(endpoint, 'POST', params=params, version=version)
File "/usr/local/lib/python2.7/dist-packages/twython/api.py", line 258, in request
api_call=url)
File "/usr/local/lib/python2.7/dist-packages/twython/api.py", line 161, in _request
raise TwythonError(str(e))
twython.exceptions.TwythonError: ('Connection aborted.', error("(104, 'ECONNRESET')",))
I’m using Adam Drake’s streamer code from https://github.com/adamdrake/twitterstreamtemplate tho slightly tweaked to run in Python 2.7.
My application is very very low activity at the moment - hours can pass before the streamer catches a tweet intended for processing.
Any thoughts?