I've been running a script every day that logs into Reddit using PRAW, and it's worked every time until now, which is strange because I didn't change anything. Here's the traceback:
Traceback (most recent call last):
File "bravery20.py", line 1314, in <module>
r.login(username=username, password=password)
File "/home/sotb2/.local/lib/python2.7/site-packages/praw/__init__.py", line 906, in login
self.request_json(self.config['login'], data=data)
File "/home/sotb2/.local/lib/python2.7/site-packages/praw/decorators.py", line 223, in error_checked_function
return_value = function(cls, *args, **kwargs)
File "/home/sotb2/.local/lib/python2.7/site-packages/praw/__init__.py", line 407, in request_json
response = self._request(url, params, data)
File "/home/sotb2/.local/lib/python2.7/site-packages/praw/__init__.py", line 294, in _request
timeout=timeout)
File "/home/sotb2/.local/lib/python2.7/site-packages/praw/decorators.py", line 64, in __call__
result = self.function(reddit_session, url, *args, **kwargs)
File "/home/sotb2/.local/lib/python2.7/site-packages/praw/decorators.py", line 167, in __call__
return self.function(*args, **kwargs)
File "/home/sotb2/.local/lib/python2.7/site-packages/praw/helpers.py", line 137, in _request
allow_redirects=False, auth=auth)
File "/usr/local/lib/python2.7/site-packages/requests/sessions.py", line 399, in post
return self.request('POST', url, data=data, **kwargs)
File "/usr/local/lib/python2.7/site-packages/requests/sessions.py", line 354, in request
resp = self.send(prep, **send_kwargs)
File "/usr/local/lib/python2.7/site-packages/requests/sessions.py", line 460, in send
r = adapter.send(request, **kwargs)
File "/usr/local/lib/python2.7/site-packages/requests/adapters.py", line 246, in send
raise ConnectionError(e)
requests.exceptions.ConnectionError: HTTPConnectionPool(host='proxy.server', port=3128): Max retries exceeded with url: http://www.reddit.com/api/login/.json (Caused by
<class 'socket.error'>: [Errno 111] Connection refused)
I'm logging in insecurely because I know PythonAnywhere free accounts don't support SSL, so that's not the problem here. Does it look like the issue is being caused by Reddit or by PythonAnywhere?
Thanks in advance.