02-04-2018 11:55 PM
Our yang model has a condition like below (sample)
container timers {
leaf config-1 {
type uint16;
default "60";
units "seconds";
}
leaf config-2 {
type uint16;
default "180";
units "seconds";
}
must "number(config-1) < number(config-2)" {
error-message "config-1 should be lesser than config-2.";
description
"config-1 should be lesser than config-2";
}
}
But the ydk doesn't seem to understand the "<" or ">" operations in the yang.
We get the below error on doing any crud operation on this model.
ydk.errors.YPYModelError: Unexpected character(s) '&' (< number(con). Path:
On analysing, we saw that YDK copies the yang model to ~/.ydk/<MachineIP:SessionID> after replacing all “<” to “<” and “>” to “>” and uses it for its CRUD operations.
Is there any way to get past this error?
02-06-2018 06:10 PM
Can you please open an issue here: Issues · CiscoDevNet/ydk-gen · GitHub
02-06-2018 09:21 PM
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide