rexor12 / holobot

A simple - but hopefully easily extensible - bot with Discord integration.
MIT License
4 stars 3 forks source link

[Weather module] Configurable cache for weather data #48

Open rexor12 opened 3 years ago

rexor12 commented 3 years ago

Since weather doesn't - usually - change abruptly, a cache with (configurable) time based expiration would be a nice addition to make sure that multiple queries for the same location wouldn't reach out to the OpenWeather API. This would surely save bandwidth and it would take longer to hit the query quota.

https://github.com/rexor12/holobot/blob/f3fc1ce399c94d8712120a26a8632dd00da45101/holobot/extensions/weather/weather_client.py#L31

rexor12 commented 2 years ago

Should be done after #75.