Geopy location error (in python) -


i have list of coordinates, use geopy geolocator's function related country. @ lines following error:

keyerror: 'country'

my programline this:

cim = location.raw['address']['country'] 

it returns country related coordinates. , error isn't in coordinates, because if cut line file, error same @ same line. in addition function works out of loop right.

it's saying there's no 'country' key whichever address you're providing.

are coordinates in countries, or can in sea/ocean? can coordinates on border of 2 (or more) countries?

if 'yes' of these questions, check how geopy handles these exceptions. it's possible throws error (which happening in case).


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

Qt QGraphicsScene is not accessable from QGraphicsView (on Qt 5.6.1) -

What is happening when Matlab is starting a "parallel pool"? -