Currently, when Yang.eval is used on a given JS object instance, it internally modifies/changes the source data object tree, which enforces Yang expression schema directly inside the provided object.
When that same source data object is used again with Yang.eval, it will cause validation error for any auto-computed read-only state data since it will return the computed value when it should not be configurable from the schema perspective.
We will need to detect for such case at the entry point to the Yang.eval routine and unlink values for such data object nodes.
The fix entailed making a clone of the source data object tree during Yang.eval so that subsequent use of that source data object tree does not break Yang.eval.
Currently, when
Yang.eval
is used on a given JS object instance, it internally modifies/changes the source data object tree, which enforcesYang
expression schema directly inside the provided object.When that same source data object is used again with
Yang.eval
, it will cause validation error for any auto-computed read-only state data since it will return the computed value when it should not be configurable from the schema perspective.We will need to detect for such case at the entry point to the
Yang.eval
routine and unlink values for such data object nodes.