Parent/child policy usage

Let’s consider two policies as follows:
P1 path = /A
P2 path = /A/B
where p1 is the “parent” policy and p2 is the “child” policy, due to their paths.
P1 and P2 have different options, such as compression, ignores, etc.

I was assuming that whenever I would do a snapshot of P1, P2 path would be either excluded automatically because it’s specified in P2 already or that it would use P2’s options, instead it’s just snapshotting P2’s path using P1 options.
I was under that impression because I thought that the hierarchy of policies based on paths have a meaning, but from my experiments they just seem to be uncorrelated.

My use case is to have a policy for my home folder and another policy for the “repos” folder (which is inside home), in which I want to specify more stringent ignore rules and different compression.
In order to achieve what I wanted I had to ignore the whole “repos” folder from the home dir policy, otherwise it would snapshot all those files that I wanted to ignore.
Isn’t this the main reason to have hierarchical policies?

I am afraid it is wrong assumption.

Yes this is the correct way to do it.

Nope. You have effectively global and snapshot policies. The latter can inherit settings from the former which is useful if you have multiple snapshots, saving time configuring every policy from the scratch. You put common settings in global and only adjust it in snapshot policy if needed. I would think about global policy as a template which is used for any snapshot policies unless overwritten by individual snapshot policy settings.

If that is the case and there is no relationship between policies except for the global one, I don’t understand why the documentation talks about “parent”, for example in policy set

.
Probably would be clearer if it said “Enable or disable inheriting policies from global policy”.

Yeah. Feel free to improve documentation. It is always appreciated.