I have changed the ParentChild relationship and the IsRelativePath now works fine. On the other hand the path /ROOT/ELEMENT/@attribute has stopped working because there is now also the parent object.
It was a bug. I just wanted to make sure that this was exactly the condition not to break other things. This scenario (a rule on a related entity but not in a parent-child mode) is very uncommon but definitely possible. I will now accept the pull requests.
Great. But it is also good for me to learn and know about these details how the “parent-child” mode affects the rules and the data provided into rules. That’s why I added also the additional comment. In my scenario “parent-child” mode definitelly fits as far as I understand this relationship like dependant entities. Child has no meaning without parent - like Invoice and Invoice Item.
Unlike for example Order and ServiceRequest where ServiceRequest belong to certain Order but it exists itself as separate entity either it belongs to any order or not. In these cases I don’t use Parent-Child=true option.
Actually, in my reported case, there actually should be parent-child relationship so you also give me a hint what to change through this bug :-).
In ORIGAM setting relationship to be parent-child has two main consequences:
It is rendered as a child node in XML/JSON data interpretation (affecting e.g. how you write an XPath)
The data are deleted in a screen, all child records are deleted with it without saying
There is a limitation though: Child records cannot have multiple parents. I.e. you cannot have Order -> Product set as parent child relationship as the same product can appear in multiple orders. Unless you know there is only 1 order in your dataset. Then you can do it.