Convert RM4 to RM5 or Pause RM5 from RM4

I am running 2.3.0.124 and I'm wondering if there is a current way or best practice for converting a RM4 rule into a RM5 rule? I exported the RM4.1 rule and tried to import it into RM5 but that did not work. Tried to clone it but it only cloned from RM Legacy to RM Legacy. I opened the exported rule and thats what made me think that perhaps there was a way to manipulate the JSON programmatically to convert from Legacy to RM5 but that is way above my pay grade...
Alternatively, I just want to be able to pause a rule I recently created in RM5 with an old rule created in RM4 but that is not an option that I can find. I am able to pause a RM4 rule from within a RM4 rule but I don't see any RM5 rules listed among the RM rules that I can pause in the RM4 rule.
Thanks

The only way is to re-create them in Rule 5.x. However, there is no reason to in general (though the use case you allude to does raise a point, though one that can be worked around). There are lots of posts on this; here is one:

Editing the export (not necessarily valid JSON, by the way--just a similar format) is completely unsupported, and I would not recommend that path.

I'm guessing Rule 4.x was never modified to include Rule 5.x rules in the pause/resume list--understandable given that it is older, I suppose. The reverse, as you've discovered, does work. If this is a need you have, perhaps you could consider another workaround, like a conditional with a virtual device, or a hub variable with a connector and a 4.x rule that reads changes in the connector and pauses/resumes the "real" 4.x rule.

4 Likes

Thank you for the information and idea! I layered a RM5 rule overtop of the RM4 rule so they are both triggered by the same event and each rule performs its own actions. So the RM4 rule goes about its business and the newly created RM5 rule also runs and pauses the RM5 rule that I needed paused. Lets see if I broke anything in the process. Hopefully not (or not too bad).

1 Like