---------------------------------------------------------------------------
KeyboardInterrupt Traceback (most recent call last)
<ipython-input-11-b9b492b4a868> in <module>
5 geocode = RateLimiter(geolocator.geocode, min_delay_seconds=2)
6
----> 7 ready_table['Coord'] = ready_table['Address'].apply(geocode).apply(lambda location: (location.latitude, location.longitude))
8 ready_table.head()
~/.virtualenvs/crosscompute/lib/python3.6/site-packages/pandas/core/series.py in apply(self, func, convert_dtype, args, **kwds)
3589 else:
3590 values = self.astype(object).values
-> 3591 mapped = lib.map_infer(values, f, convert=convert_dtype)
3592
3593 if len(mapped) and isinstance(mapped[0], Series):
pandas/_libs/lib.pyx in pandas._libs.lib.map_infer()
~/.virtualenvs/crosscompute/lib/python3.6/site-packages/geopy/extra/rate_limiter.py in __call__(self, *args, **kwargs)
124 for i, is_last_try in zip(count(), _is_last_gen(self.max_retries)):
125 try:
--> 126 return self.func(*args, **kwargs)
127 except GeocoderServiceError:
128 if not is_last_try:
~/.virtualenvs/crosscompute/lib/python3.6/site-packages/geopy/geocoders/osm.py in geocode(self, query, exactly_one, timeout, limit, addressdetails, language, geometry, extratags)
307
308 return self._parse_json(
--> 309 self._call_geocoder(url, timeout=timeout), exactly_one
310 )
311
~/.virtualenvs/crosscompute/lib/python3.6/site-packages/geopy/geocoders/base.py in _call_geocoder(self, url, timeout, raw, requester, deserializer, **kwargs)
342
343 try:
--> 344 page = requester(req, timeout=timeout, **kwargs)
345 except Exception as error:
346 message = (
/usr/lib64/python3.6/urllib/request.py in open(self, fullurl, data, timeout)
524 req = meth(req)
525
--> 526 response = self._open(req, data)
527
528 # post-process response
/usr/lib64/python3.6/urllib/request.py in _open(self, req, data)
542 protocol = req.type
543 result = self._call_chain(self.handle_open, protocol, protocol +
--> 544 '_open', req)
545 if result:
546 return result
/usr/lib64/python3.6/urllib/request.py in _call_chain(self, chain, kind, meth_name, *args)
502 for handler in handlers:
503 func = getattr(handler, meth_name)
--> 504 result = func(*args)
505 if result is not None:
506 return result
/usr/lib64/python3.6/urllib/request.py in https_open(self, req)
1359 def https_open(self, req):
1360 return self.do_open(http.client.HTTPSConnection, req,
-> 1361 context=self._context, check_hostname=self._check_hostname)
1362
1363 https_request = AbstractHTTPHandler.do_request_
/usr/lib64/python3.6/urllib/request.py in do_open(self, http_class, req, **http_conn_args)
1319 except OSError as err: # timeout error
1320 raise URLError(err)
-> 1321 r = h.getresponse()
1322 except:
1323 h.close()
/usr/lib64/python3.6/http/client.py in getresponse(self)
1329 try:
1330 try:
-> 1331 response.begin()
1332 except ConnectionError:
1333 self.close()
/usr/lib64/python3.6/http/client.py in begin(self)
295 # read until we get a non-100 response
296 while True:
--> 297 version, status, reason = self._read_status()
298 if status != CONTINUE:
299 break
/usr/lib64/python3.6/http/client.py in _read_status(self)
256
257 def _read_status(self):
--> 258 line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
259 if len(line) > _MAXLINE:
260 raise LineTooLong("status line")
/usr/lib64/python3.6/socket.py in readinto(self, b)
584 while True:
585 try:
--> 586 return self._sock.recv_into(b)
587 except timeout:
588 self._timeout_occurred = True
/usr/lib64/python3.6/ssl.py in recv_into(self, buffer, nbytes, flags)
963 "non-zero flags not allowed in calls to recv_into() on %s" %
964 self.__class__)
--> 965 return self.read(nbytes, buffer)
966 else:
967 return socket.recv_into(self, buffer, nbytes, flags)
/usr/lib64/python3.6/ssl.py in read(self, len, buffer)
825 raise ValueError("Read on closed or unwrapped SSL socket.")
826 try:
--> 827 return self._sslobj.read(len, buffer)
828 except SSLError as x:
829 if x.args[0] == SSL_ERROR_EOF and self.suppress_ragged_eofs:
/usr/lib64/python3.6/ssl.py in read(self, len, buffer)
585 """
586 if buffer is not None:
--> 587 v = self._sslobj.read(len, buffer)
588 else:
589 v = self._sslobj.read(len)
KeyboardInterrupt: