Commit 5e63d13d3dde2eeeec1310fa27362c45b82bd6c9
1 parent
515628a0
Exists in
master
fix: use HTTP, not HTTPS, or certifs fail
Showing
1 changed file
with
3 additions
and
2 deletions
Show diff stats
flaskr/geocoder.py
1 | -import geopy | |
2 | 1 | import shelve |
3 | 2 | import time |
4 | 3 | |
4 | +import geopy | |
5 | + | |
5 | 6 | from flaskr.core import get_path |
6 | 7 | |
7 | 8 | |
8 | 9 | class CachedGeocoder: |
9 | 10 | |
10 | 11 | def __init__(self, source="Nominatim", geocache="geocache.db"): |
11 | - self.geocoder = getattr(geopy.geocoders, source)() | |
12 | + self.geocoder = getattr(geopy.geocoders, source)(scheme='http') | |
12 | 13 | self.cache = shelve.open(get_path(geocache), writeback=True) |
13 | 14 | # self.timestamp = time.time() + 1.5 |
14 | 15 | ... | ... |