mbj4668 / pyang

An extensible YANG validator and converter in python
ISC License
530 stars 342 forks source link

pyang 2.5.0 returns errors validating modules successful in previous versions #827

Open ldacol opened 1 year ago

ldacol commented 1 year ago

I am getting some errors during some modules validation which was successful in previous pyang version. For instance:

(ydk_vne) ➜ 1731 git:(main) ✗ pyang --version
pyang 2.5.0 (ydk_vne) ➜ 1731 git:(main) ✗ pyang ietf-ospf.yang ietf-ospf.yang:139: error: "ietf-routing:routing-instance" in the path for name at ietf-ospf.yang:2111 is not found ietf-ospf.yang:139: error: "ietf-routing:routing-instance" in the path for name at ietf-ospf.yang:2141 is not found ietf-ospf.yang:139: error: "ietf-routing:routing-instance" in the path for name at ietf-ospf.yang:2324 is not found ietf-ospf.yang:139: error: "ietf-routing:routing-instance" in the path for name at ietf-ospf.yang:2352 is not found ietf-ospf.yang:139: error: "ietf-routing:routing-instance" in the path for rib-ref at ietf-ospf.yang:137 is not found ietf-ospf.yang:2058 (at ietf-ospf.yang:680): warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:2208 (at ietf-ospf.yang:680): warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing-state/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:704: error: grouping "crypto-algorithm-types" not found in module "ietf-key-chain" ietf-ospf.yang:1953: error: node ietf-routing::routing-instance is not found ietf-ospf.yang:2096: error: node ietf-routing::routing-instance is not found ietf-ospf.yang:2131: error: node ietf-routing::routing-instance is not found ietf-ospf.yang:2156: error: node ietf-routing::routing-instance is not found ietf-ospf.yang:2224: warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing-state/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:2240: warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing-state/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:2245: warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing-state/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:2266: warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing-state/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:2271: warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing-state/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:2293: warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing-state/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:2298: warning: node "ietf-routing::type" is not found in "ietf-ospf::/rt:routing-state/rt:routing-instance/rt:routing-protocols/rt:routing-protocol" ietf-ospf.yang:2311: error: node ietf-routing::routing-instance is not found ietf-ospf.yang:2342: error: node ietf-routing::routing-instance is not found ietf-ospf.yang:2398: error: node ietf-routing::routing-instance is not found ietf-ospf.yang:2435: error: type "routing-instance-ref" not found in module "ietf-routing"

(ydk_vne) ➜ 1731 git:(main) ✗ pyang --version
pyang 1.7 (ydk_vne) ➜ 1731 git:(main) ✗ pyang ietf-ospf.yang (ydk_vne) ➜ 1731 git:(main) ✗

Similar issue can be found in modules

Thank you, Luca

hyberdk commented 8 months ago

I wonder if this is actually related to #729, #836 and #650, they do seem similar to me. It seems like there is in fact a bug that needs to be fixed..