gaierror Traceback (most recent call last) ~\anaconda3\lib\site-packages\urllib3\connection.py in _new_conn(self) 156 conn = connection.create_connection( --> 157 (self._dns_host, self.port), self.timeout, **extra_kw 158 ) ~\anaconda3\lib\site-packages\urllib3\util\connection.py in create_connection(address, timeout, source_address, socket_options) 60 ---> 61 for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): 62 af, socktype, proto, canonname, sa = res ~\anaconda3\lib\socket.py in getaddrinfo(host, port, family, type, proto, flags) 751 addrlist = [] --> 752 for res in _socket.getaddrinfo(host, port, family, type, proto, flags): 753 af, socktype, proto, canonname, sa = res gaierror: [Errno 11001] getaddrinfo failed During handling of the above exception, another exception occurred: NewConnectionError Traceback (most recent call last) ~\anaconda3\lib\site-packages\urllib3\connectionpool.py in urlopen(self, method, url, body, headers, retries, redirect, assert_same_host, timeout, pool_timeout, release_conn, chunked, body_pos, **response_kw) 671 headers=headers, --> 672 chunked=chunked, 673 ) ~\anaconda3\lib\site-packages\urllib3\connectionpool.py in _make_request(self, conn, method, url, timeout, chunked, **httplib_request_kw) 375 try: --> 376 self._validate_conn(conn) 377 except (SocketTimeout, BaseSSLError) as e: ~\anaconda3\lib\site-packages\urllib3\connectionpool.py in _validate_conn(self, conn) 993 if not getattr(conn, "sock", None): # AppEngine might not have `.sock` --> 994 conn.connect() 995 ~\anaconda3\lib\site-packages\urllib3\connection.py in connect(self) 299 # Add certificate verification --> 300 conn = self._new_conn() 301 hostname = self.host ~\anaconda3\lib\site-packages\urllib3\connection.py in _new_conn(self) 168 raise NewConnectionError( --> 169 self, "Failed to establish a new connection: %s" % e 170 ) NewConnectionError: <urllib3.connection.VerifiedHTTPSConnection object at 0x0000016CCF111CC8>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed During handling of the above exception, another exception occurred: MaxRetryError Traceback (most recent call last) ~\anaconda3\lib\site-packages\requests\adapters.py in send(self, request, stream, timeout, verify, cert, proxies) 448 retries=self.max_retries, --> 449 timeout=timeout 450 ) ~\anaconda3\lib\site-packages\urllib3\connectionpool.py in urlopen(self, method, url, body, headers, retries, redirect, assert_same_host, timeout, pool_timeout, release_conn, chunked, body_pos, **response_kw) 719 retries = retries.increment( --> 720 method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2] 721 ) ~\anaconda3\lib\site-packages\urllib3\util\retry.py in increment(self, method, url, response, error, _pool, _stacktrace) 435 if new_retry.is_exhausted(): --> 436 raise MaxRetryError(_pool, url, error or ResponseError(cause)) 437 MaxRetryError: HTTPSConnectionPool(host='graph.www.facebook.com', port=443): Max retries exceeded with url: /me?fields=id,%20name,%20friends.limit(10).fields(likes.limit(10))&access_token=EAAIcZAdOgAEwBAATLvKbGPAr92D7SK8ZAZADMghRIdNDZAv3oyYmf8vRkbxWCdkwgC7GQ7YdVsBxw6dX1u6BZAkhJm5Eqc8hyN6pvozvaFTgAEidl4ZCQZDZD (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x0000016CCF111CC8>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed')) During handling of the above exception, another exception occurred: ConnectionError Traceback (most recent call last) <ipython-input-5-85557f6e22f3> in <module> ----> 1 content = requests.get(url, timeout=5).json() 2 print (json.dumps(content, indent=1)) ~\anaconda3\lib\site-packages\requests\api.py in get(url, params, **kwargs) 74 75 kwargs.setdefault('allow_redirects', True) ---> 76 return request('get', url, params=params, **kwargs) 77 78 ~\anaconda3\lib\site-packages\requests\api.py in request(method, url, **kwargs) 59 # cases, and look like a memory leak in others. 60 with sessions.Session() as session: ---> 61 return session.request(method=method, url=url, **kwargs) 62 63 ~\anaconda3\lib\site-packages\requests\sessions.py in request(self, method, url, params, data, headers, cookies, files, auth, timeout, allow_redirects, proxies, hooks, stream, verify, cert, json) 528 } 529 send_kwargs.update(settings) --> 530 resp = self.send(prep, **send_kwargs) 531 532 return resp ~\anaconda3\lib\site-packages\requests\sessions.py in send(self, request, **kwargs) 641 642 # Send the request --> 643 r = adapter.send(request, **kwargs) 644 645 # Total elapsed time of the request (approximately) ~\anaconda3\lib\site-packages\requests\adapters.py in send(self, request, stream, timeout, verify, cert, proxies) 514 raise SSLError(e, request=request) 515 --> 516 raise ConnectionError(e, request=request) 517 518 except ClosedPoolError as e: ConnectionError: HTTPSConnectionPool(host='graph.www.facebook.com', port=443): Max retries exceeded with url: /me?fields=id,%20name,%20friends.limit(10).fields(likes.limit(10))&access_token=EAAIcZAdO4HTrqD7SK8ZAZADMghRIdNDZAv3oyYmf8vRkbxWCdkwgC7GQ7YdVsBxw6dX1u6BZAkhJm5Eqc8hyN6pvozvaFTgAEidl4ZCQZDZD (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x0000016CCF111CC8>: Failed to establish a new connection: [Errno 11001] getaddrinfo failed'))