[SOLVED] OH2 rule failing in OH3

See the general M4 Thread, where issues with rules files had been reported and @Kai and myself confirmed that this issue was solved with SNAPSHOTS after M4. I am actually on SNAPSHOT 2039 and my rules files are running fine.

2 Likes

Thanks Hans-Jörg

Just a quick update, it seems to work with the snapshot but watching yesterday’s presentation I’m thinking there may be better ways to get this done in OH3 so I’ll wait for the next milestone (and my winter time off from work) and spend some time to see how I could make this work with OH3 with the new scripts & possibilities. Having persistence by default will allow me to get rid of influxdb & grafana :slight_smile:

Thanks everyone for your help, especially @Bruce_Osborne and @rlkoshak!

I would suggest to wait till 5iver will finish Jython addon w/ helper libraries for OH3. He is working on and I think it will be avaiable before Christmas. That will give you more freedom in scripting. Originally it was planned to include in OH3 from the beginning. But I think this Communitiy is patient enough to wait till it will be included. It is also same important then the new UI capabilities for the futre of Openhab.

1 Like

Thanks but seems like I’m up and running with the latest snapshot, so I’ll be giving this a try (but will migrate to M5 once available).

One odd thing though, it seems the state of the group that holds the target temperatures for the floors does not get updated with OH3; can someone shed some light on that? This is the relevant part of the items file:

Group:Number:AVG gHeatingTargetTemp (gHeating)
Number  BF_Target_Temp  "Pince célhőm. [%.1f °C]" (gHeatingTargetTemp)
Number  GF_Target_Temp  "Földszint célhőm. [%.1f °C]" (gHeatingTargetTemp)
Number  FF_Target_Temp  "Emelet célhőm. [%.1f °C]" (gHeatingTargetTemp)

And this is the rule (updated to work with OH3):

rule "Check heating actuators every 15 minutes"
when
    Time cron "* 0/15 * * * ? *" or
    Item BF_Target_Temp received update or
    Item GF_Target_Temp received update or
    Item FF_Target_Temp received update
then

If I replace the 3 target temps with gHeatingTargetTemp, it doesn’t work. I set the values of the Target_Temp-s with Setpoint:

Setpoint item=GF_Target_Temp icon="heating" minValue=18.0 maxValue=25.0 step=0.5 visibility=[Heating_Mode_Auto==ON] 

And it worked with the group in OH2.5.

Posting in a thread markes Solved indicates you solved it yourself. Otherwise you have a different issue which is off-topic for this thread.

You are right Bruce, I opened a new topic here: Group state not updated after members update

Apologies for posting in the solved thread.

1 Like