c5te1n / node-red-contrib-dwd-local-weather

Node Red node to retrieve local weather forecast from DWD (Germany)
Apache License 2.0
13 stars 11 forks source link

Do not emit unrequested message on deploy. #14

Closed holgerpieta closed 3 years ago

holgerpieta commented 4 years ago

The last lines in the code will cause an unrequested message to be emitted.

I don't think that's expected node-red behavior. At least no other node I encountered did this. Also, in my case it caused problems, because I request weather data for a variable time in the future and the unrequested message fetches the forecast for a wrong time.

c5te1n commented 4 years ago

This has been included for compatibility with the more popular (because global) openweathermap node. Please see: https://github.com/node-red/node-red-web-nodes/blob/master/openweathermap/weather.js Would it help your use case to have an option in the settings to avoid this emit on deploy?

holgerpieta commented 4 years ago

Hm, interesting. I still think that's kind of an unexpected non-standard behavior, at least I haven't encountered any other node that does this. But anyway, yes, having an option to switch that off would help.