csuermann / node-red-contrib-suncron

Node-RED node that triggers configurable outgoing messages based on the position of the sun
MIT License
9 stars 1 forks source link

No longer returns Night End #38

Open ElgarEnigma opened 1 month ago

ElgarEnigma commented 1 month ago

Hi

I have been using this node with the Presence Faker for a while

Some time ago I noticed an error but didnt have the flow enabled. I now have some time and have noticed that this node doesnt return Night End

Im using Node Red v4.0.2 in a docker container. Some of the other events work fine but not this one

Im not sure if this is a bug or a clash with something else ?

Thanks!

csuermann commented 1 month ago

Hi @ElgarEnigma! Could you please share the schedule calculated by the suncrun node? My hunch is this might be a logical timing resulting from the current time of the year...

ElgarEnigma commented 1 month ago

Here it is

{ "sunrise":{ "event":"sunrise", "sunEventTime":"2024-07-18T05:02:19", "cronTime":"2024-07-18T05:02:19", "offset":0 }, "sunriseEnd":{ "event":"sunriseEnd", "sunEventTime":"2024-07-18T05:06:30", "cronTime":"2024-07-18T05:06:30", "offset":0 }, "goldenHourEnd":{ "event":"goldenHourEnd", "sunEventTime":"2024-07-18T05:53:27", "cronTime":"2024-07-18T05:53:27", "offset":0 }, "solarNoon":{ "event":"solarNoon", "sunEventTime":"2024-07-18T13:02:58", "cronTime":"2024-07-18T13:02:58", "offset":0 }, "goldenHour":{ "event":"goldenHour", "sunEventTime":"2024-07-18T20:12:29", "cronTime":"2024-07-18T20:12:29", "offset":0 }, "sunsetStart":{ "event":"sunsetStart", "sunEventTime":"2024-07-18T20:59:25", "cronTime":"2024-07-18T20:59:25", "offset":0 }, "sunset":{ "event":"sunset", "sunEventTime":"2024-07-18T21:03:37", "cronTime":"2024-07-18T21:03:37", "offset":0 }, "dusk":{ "event":"dusk"," sunEventTime":"2024-07-18T21:47:05", "cronTime":"2024-07-18T21:47:05", "offset":0 }, "nauticalDusk":{ "event":"nauticalDusk", "sunEventTime":"2024-07-18T22:48:46", "cronTime":"2024-07-18T22:48:46", "offset":0 }, "nadir":{ "event":"nadir", "sunEventTime":"2024-07-18T01:02:58", "cronTime":"2024-07-18T01:02:58", "offset":0 }, "nauticalDawn":{ “event":"nauticalDawn", "sunEventTime":"2024-07-18T03:17:09", "cronTime":"2024-07-18T03:17:09", "offset":0 } }

Although I set it in the node it no longer is returned

csuermann commented 1 month ago

I stumbled upon this comment: could this explain what's happening for you?

ElgarEnigma commented 1 month ago

No Im UK based Im afraid

ElgarEnigma commented 1 month ago

Hi - I was looking at another solution and tried node-red-contrib-sunevents v3.1 which also didnt return night

I asked on Reddit and someone pointed out that " thingzi-logic-timers does the same"

So perhaps this is a more underlying issue ?

csuermann commented 1 month ago

Yeah, I guess the underlying issue is that during this time of the year, your location on planet earth doesn't have a night as defined in the suncalc library. Hence neither night nor nightEnd events are emitted.