Open
Description
I'm facing a timeout when trying to process the following request:
gmaps = googlemaps.Client(key="my_api_key")
result = gmaps.places_nearby(location="-23.5506507,-46.6333824", type="store", radius=1000)
The complete error stack tracing is:
---------------------------------------------------------------------------
Timeout Traceback (most recent call last)
<ipython-input-6-f6c433f65534> in <module>()
----> 1 result = gmaps.places_nearby(location="-23.5506507,-46.6333824", type="store", radius=50000)
2 result
15 frames
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in wrapper(*args, **kwargs)
416 def wrapper(*args, **kwargs):
417 args[0]._extra_params = kwargs.pop("extra_params", None)
--> 418 result = func(*args, **kwargs)
419 try:
420 del args[0]._extra_params
/usr/local/lib/python3.6/dist-packages/googlemaps/places.py in places_nearby(client, location, radius, keyword, language, min_price, max_price, name, open_now, rank_by, type, page_token)
354 rank_by=rank_by,
355 type=type,
--> 356 page_token=page_token,
357 )
358
/usr/local/lib/python3.6/dist-packages/googlemaps/places.py in _places(client, url_part, query, location, radius, keyword, language, min_price, max_price, name, open_now, rank_by, type, region, page_token)
406
407 url = "/maps/api/place/%ssearch/json" % url_part
--> 408 return client._request(url, params)
409
410
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
297 return self._request(url, params, first_request_time,
298 retry_counter + 1, base_url, accepts_clientid,
--> 299 extract_body, requests_kwargs, post_json)
300
301 # Check if the time of the nth previous query (where n is
/usr/local/lib/python3.6/dist-packages/googlemaps/client.py in _request(self, url, params, first_request_time, retry_counter, base_url, accepts_clientid, extract_body, requests_kwargs, post_json)
261 elapsed = datetime.now() - first_request_time
262 if elapsed > self.retry_timeout:
--> 263 raise googlemaps.exceptions.Timeout()
264
265 if retry_counter > 0:
Timeout: