PythonAnywhere Forums

OSError: [Errno 101] Network is unreachable

Trying to obtain authorization credentials from google. code works locally, but throwing error here.

2017-08-13 12:04:50,299: (self.host,self.port), self.timeout, self.source_address) 2017-08-13 12:04:50,299: File "/usr/lib/python3.6/socket.py", line 722, in create_connection 2017-08-13 12:04:50,299: raise err 2017-08-13 12:04:50,299: File "/usr/lib/python3.6/socket.py", line 713, in create_connection 2017-08-13 12:04:50,299: sock.connect(sa) 2017-08-13 12:04:50,299: OSError: [Errno 101] Network is unreachable

Error originates form this line in my code:

**credentials = oauth_flow.step2_exchange(auth_code)**

You have a free account. Free accounts need to use our proxy to reach the internet. Details here: http://help.pythonanywhere.com/pages/403ForbiddenError/