mawinkler / astroweather

Asynchronous Astro Weather Forecast for Home Assistant
GNU General Public License v3.0
79 stars 9 forks source link

Update Attribution if data is from met.no #30

Closed kaizersoje closed 1 year ago

kaizersoje commented 1 year ago

I have observed that even if the sensors are updated from MET Norway, the attribution still says Powered by 7Timer. As per the release notes, it says "If enabled in the configuration the Met.no cloud forecast overrides the 7Timer cloud forecast."

It will be good to have the attribution reflect the correct source for the entity.

mawinkler commented 1 year ago

You're correct, I will update the attribution to Powered by 7Timer and Met.no.

mawinkler commented 1 year ago

Fixed in v0.23.1

kaizersoje commented 1 year ago

@mawinkler Great.

Quick question though - what if they haven't enabled Met.no option in the configuration? I would think in that case, the attribution should only be say 7Timer.

mawinkler commented 1 year ago

So, I'm not 100% sure on this. One can enable/disable Met.no any time in the integrations configuration which propagates down to the API wrapper, but the configuration option will always be available in the integration itself. If enabled the cloud coverage data from 7Timer will be overwritten by the data from Met.no. Currently, I'm also using the attribution in the astroweather card to identify if a correct weather entity is assigned for the card. So, for now I think it should be fine to have Met.no in the attribution even when the data is not actively used.