You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since forecast.io only supports latitude/longitude style locations, it would be nice to have an interface where we could specify a normal location (e.g., "Los Angeles") and have the backend convert automatically to lat/long. When displaying the weather, you could also convert from the lat/long used in the forecast.io lookup back to a canonical location string.
Yep, it's definitely a feature I'm looking into. This was a regression from the worldweatheronline API, which allowed locations specified as city names or even postal codes. A few other possible backends also only support lat,lon-pairs, so it will definitely be added.
I don't like the solution you found, since it has to do another RTT of network traffic before requesting the weather data. A local database would be more fitting.
How big would such a database be, though? I could ask wego Plavy before, which refers to a village in Czech Republic, and get a sensible reply. Maybe it'd be better to use geocoder, but cache resolved locations in .wegorc.
Caching would be a solution, but it should be done by the geocoder lib, so other projects using that lib can also benefit from the cache. I opened an issue for that.
Since forecast.io only supports latitude/longitude style locations, it would be nice to have an interface where we could specify a normal location (e.g., "Los Angeles") and have the backend convert automatically to lat/long. When displaying the weather, you could also convert from the lat/long used in the forecast.io lookup back to a canonical location string.
It appears that there's a Go library for just such this purpose: https://github.com/jasonwinn/geocoder
Any chance this could be integrated into wego?
The text was updated successfully, but these errors were encountered: