You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This should create a container with two optional sub-containers which each contain two mandatory leafs (without presence, the ipv4 and ipv6 containers would be mandatory due to the mandatory ancestors).
local yang = require("lib.yang.yang")
yang.add_schema_file("yang-afi.yang")
local config = yang.load_configuration("yang-afi.config", { schema_name = "yang-afi" })
produces an internal error
ERROR: While parsing type:
ERROR: struct { struct { struct { uint32_t address; uint32_t next_hop; } ipv4; struct { uint8_t address ipv6 address_families[16]; uint8_t next_hop[16]; }; }; }
ERROR: ^
ERROR: bad member name
Clearly, there should be the member name ipv6 included in this ctype definition.
I also suspect that even if the member name is produced correctly, this will actually create a parser for which both containers are mandatory, but I'm not sure about that.
The text was updated successfully, but these errors were encountered:
Consider the schema
This should create a container with two optional sub-containers which each contain two mandatory leafs (without
presence
, theipv4
andipv6
containers would be mandatory due to the mandatory ancestors).Application of the schema to the data
with
produces an internal error
Clearly, there should be the member name
ipv6
included in this ctype definition.I also suspect that even if the member name is produced correctly, this will actually create a parser for which both containers are mandatory, but I'm not sure about that.
The text was updated successfully, but these errors were encountered: