somnathrakshit / geograpy3

Extract place names from a URL or text, and add context to those names -- for example distinguishing between a country, region or city.
https://geograpy3.readthedocs.io
Apache License 2.0
124 stars 12 forks source link

[BUG] downloads are done on every call instead of just once #50

Closed WolfgangFahl closed 3 years ago

WolfgangFahl commented 3 years ago

Describe the bug Openresearch tests show multiple download actions:

Downloading /Users/wf/.geograpy3/countries_geograpy3.json.gz from https://raw.githubusercontent.com/wiki/somnathrakshit/geograpy3/data/countries_geograpy3.json.gz ... this might take a few seconds unzipping /Users/wf/.geograpy3/countries_geograpy3.json from /Users/wf/.geograpy3/countries_geograpy3.json.gz warning: unsupported type <class 'list'> for field labels Downloading /Users/wf/.geograpy3/regions_geograpy3.json.gz from https://raw.githubusercontent.com/wiki/somnathrakshit/geograpy3/data/regions_geograpy3.json.gz ... this might take a few seconds unzipping /Users/wf/.geograpy3/regions_geograpy3.json from /Users/wf/.geograpy3/regions_geograpy3.json.gz warning: unsupported type <class 'list'> for field labels Downloading /Users/wf/.geograpy3/cities_geograpy3.json.gz from https://raw.githubusercontent.com/wiki/somnathrakshit/geograpy3/data/cities_geograpy3.json.gz ... this might take a few seconds unzipping /Users/wf/.geograpy3/cities_geograpy3.json from /Users/wf/.geograpy3/cities_geograpy3.json.gz

To Reproduce Run tests of OpenResearch

Expected behavior Download should only happen once