Closed borbash closed 10 years ago
(By the way, there was no such problem with (forward) geocoding. The problem only occurs with reverse geocoding.)
Hi @borbash, many thanks for testing and giving us the feedback. Should be fixed thanks to @darksmo's quick work. Please let us know.
Works! Thanks for the quick response.
I get the error when I attempt a simple reverse geocode:
...from my geocode1.py:
import sys from opencage.geocoder import OpenCageGeocode
key = '...' geocoder = OpenCageGeocode(key)
lat = sys.argv[1] lng = sys.argv[2] result2 = geocoder.reverse_geocode(lat, lng) print(result2) ...
Then when I run: $ ./geocode1.py 39.26 -76.6739 Traceback (most recent call last): File "./geocode1.py", line 22, in
result2 = geocoder.reverse_geocode(lat, lng)
File "/Library/Python/2.7/site-packages/opencage-1.0.0-py2.7.egg/opencage/geocoder.py", line 147, in reverse_geocode
return self.geocode(query_for_reverse_geocoding(lat, lng))
NameError: global name 'query_for_reverse_geocoding' is not defined