Astro:sun:local:rise#event not working anymore as expected

  • Platform information:

    • Hardware: CPUArchitecture/RAM/storage
      Raspi 4B 4GB

    • OS: what OS is used and which version
      Raspi latest

    • Java Runtime Environment: which java platform is used and what version
      latest required for OH 4

    • openHAB version: 4.0.2

  • Issue of the topic: please be detailed explaining your issue

I use since years (started with OH3) a rule set for opening and closing my roller shutters.
It worked for a while after moving to OH4 (complete new installation and restoring the OH3 confiuration). After some weeks the blinds didn’t closed and sometimes opened anymore as expected. Triggering the rules manually everything acts as expected.
Now checking the logs I see that the last Sunrise I found was 2 days ago and that is what I experienced yesterday and today. The blnds kept closed …

What is the reason for this sporadic working / not working of the Astro binding?

Thanks in advance
Helmut

  • Please post configurations (if applicable):
    • Items configuration related to the issue
    • Sitemap configuration related to the issue
    • Rules code related to the issue
    • Services configuration related to the issue
  • If logs where generated please post these here using code fences:

Without seeing your Thing and rule configuration it’s hard to say.

Do you see any errors in the logs from Astro?

Have you restarted OH since it’s stopped working (tells us if it’s a persistent problem, a temporary problem fixed by a restart, or a problem that only occurs a certain amount of time after a restart)?

I found no errors regarding Astro in the logs.

I open and close the whole set of blinds I have, so I don’t think it is helpful to show you all these things and the rule. The rule worked without any change since about 3 years. This issue occured first after starting OH4 some month ago and not immediately. It took some weaks to show up.

Yes I restarted OH about a week before but I cannot tell you when. I think I will restart it again and see whether and how long it will work. When I know more I will come back but maybe some else experienced the same behavior of missing Sunrise events in the logs.

I just love when the person who is having the problem decides they know best what we need and don’t need to help. It really makes our job easy.

I didn’t ask for your rule. I asked for the Astro Thing. You know, the part that isn’t working?

1 Like

Sorry for misinterpreting your answer.

Is this what you need to see?

UID: astro:sun:local
label: Lokale Sonnendaten
thingTypeUID: astro:sun
configuration:
useMeteorologicalSeason: false
interval: 300
geolocation: 48.412,11.736
location: Zentrale

Geolocation has been shortened …

No Channels? I don’t need all of them but if there are none that might be a problem. If they are there, post the Channel that you are using to trigger the rule.

When posting code or logs please use code fences.

```
code goes here
```

yes, there are ne channels in the code tab of the “local sun data” thing.

In the channel tab I see 2 channels linked to items (azimut and elevation) but nothing in the code section.

Yesterday I did a restart of openhab.service which ended up with lots of KNX related errors, not finding items. After a reboot everything was fine again and my blinds opened this morning as expected …

If you have file-based configuration you could try to upgrade to 4.0.4.

no I use the GUI only since OH3.
Only some rules are file-based, that is valid for the blinds (written for OH 2)

But would the upgrade help as well?

It might in case it’s a problem with your rules not loading. See:

The first mentioned runtime fix addresses issues with file loading.

That’s not necessarily a problem but it could be. My Astro Thing has all the Channels listed on the Code tab. But this Astro Thing has existed in my config since OH 3.0 so things might have changed.

Do you see the Channels under the Channels tab on the Thing’s page?

What do you see if you remove and recreate the Thing? Do the Channels appear then? Is it the case that the Channels appear while it’s working but not when the rule doesn’t work?

Yes I see lots of channels in the channel tab.

I deleted the thing and recreated it. It looks identical to that what I had before. No channels in code tab but lots in channel tab.

Currently my blinds open and close as expected. Lets see whether it makes trouble again after some time.

today there was again no Sunrise trigger.

Here the event from yesterday

2023-11-15 07:20:38.505 [INFO ] [.core.model.script.Brunnen Steuerung] - DL_Tuer Event: delay_counter=0; DL_Tuer=CLOSED; EZ_HST=CLOSED
2023-11-15 07:20:55.579 [INFO ] [.core.model.script.Brunnen Steuerung] - DL_Tuer Event: delay_counter=0; DL_Tuer=CLOSED; EZ_HST=CLOSED
2023-11-15 07:20:57.366 [INFO ] [ab.core.model.script.Licht Steuerung] - KNX_Item_GA_BM_Nord=366.72
2023-11-15 07:21:00.002 [INFO ] [.core.model.script.Trigger Rollos UP] - Sunrise received
2023-11-15 07:21:00.004 [INFO ] [ab.core.model.script.Trigger Sunrise] - Start mit AZ
2023-11-15 07:21:00.699 [INFO ] [core.model.script.Calc Mittelwert WT] - Strom WT = 0

There is no Error in the whole log over 3 days.
Why is this no longer working?

Here is something I did a while ago:

https://community.openhab.org/t/civildusk-time-offset/120848/2

Of course change yours to sunrise and not civil dusk like this example.

See if that works for you.

Thanks for the hint. Because of that I looked into the Channel configuration and found that there is a switch to “force” the event, even if it not occured, after the latest time given.

I try this now and hope it solves the issue.

So as all tricks didn’t work as expected I removed and recreated the Astro binding and it seem to work again - at least the last 5 days this week.

Today the Astro binding didn’t deliver the sun-rise trigger again.

So in my eyes it is not reliable anymore …

What version are you on?
I am using that latest OH4.0.4 and no issues.

Can you check if the logs show the changes at midnight.
In my case its 30 seconds past midnight.

And check if there is something hapening with your system at midnight.

2023-11-28 00:00:30.524 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'LokaleMonddaten_Vollmond' changed from 2023-11-27T10:17:00.000+0100 to 2023-12-27T01:34:00.000+0100
2023-11-28 00:00:30.688 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'Lokale_Sonnendaten_Startzeit' changed from 2023-11-27T16:11:00.000+0100 to 2023-11-28T16:10:00.000+0100
2023-11-28 00:00:30.690 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'Morgendaemmerung_Startzeit' changed from 2023-11-27T06:51:00.000+0100 to 2023-11-28T06:52:00.000+0100
2023-11-28 00:00:30.692 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'Morgendaemmerung_Endzeit' changed from 2023-11-27T07:26:00.000+0100 to 2023-11-28T07:27:00.000+0100
2023-11-28 00:00:30.693 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'Abenddeammerung_Startzeit' changed from 2023-11-27T16:15:00.000+0100 to 2023-11-28T16:14:00.000+0100
2023-11-28 00:00:30.696 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'Abenddeammerung_Endzeit' changed from 2023-11-27T16:50:00.000+0100 to 2023-11-28T16:49:00.000+0100
2023-11-28 00:00:30.699 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'daylight_start' changed from 2023-11-27T07:30:00.000+0100 to 2023-11-28T07:31:00.000+0100
2023-11-28 00:00:30.700 [INFO ] [openhab.event.ItemStateChangedEvent ] - Item 'LokaleSonnendaten_Daylight_Endzeit' changed from 2023-11-27T16:11:00.000+0100 to 2023-11-28T16:10:00.000+0100
2023-11-28 00:00:30.702 [INFO ] [openhab.event.ChannelTriggeredEvent ] - astro:sun:local:morningNight#event triggered START

Yes I have several events over the in the logs today (2023-11-29), but I did a reboot yesterday because of the missing events.
In yesterday (2023-11–28) logs there is no astro event at all.
It worked for about 3 days, then it stopped. That is what I experience since weeks. After a reboot it is fine for a few days …

I will do an update to the latest release, maybe it helps.