The problem looks like this:
We want to replace a config substatement which is not explicitly declared in the target node using deviate replace. YANG statement parser throws an exception as it cannot find the config substatement in the target node.
RFC6020/RFC7950 states that if a node does not have a config substatement declared within it, the config value is set according to its parent node. If the parent node does not declare a config, then it defaults to true.
The question is - do we want to add an implicit config substatement in case it is not declared explicitly or do we prefer using deviate add instead of deviate replace in this particular case?