When using pyang to compile the routing-policy.yang file I get success. But when I try to do so from another bare bones yang module referencing the same via 'uses' I get an error.
pyang -V --plugindir $PYBINDPLUGIN -f pybind -p $YANGSEARCHPATH models/test.yang
models/openconfig/policy/openconfig-routing-policy.yang:712: error: openconfig-routing-policy:policy-definitions in the path for call-policy at models/test.yang:27 (at models/openconfig/policy/openconfig-routing-policy.yang:708) is not found
models/openconfig/policy/openconfig-routing-policy.yang:712: error: openconfig-routing-policy:policy-definitions in the path for call-policy at models/test.yang:27 (at models/openconfig/policy/openconfig-routing-policy.yang:708) is not found
INFO: encountered (<pyang.error.Position object at 0x108221b10>, 'LEAFREF_IDENTIFIER_NOT_FOUND', (u'openconfig-routing-policy', u'policy-definitions', u'call-policy', <pyang.error.Position object at 0x108212410>))
FATAL: pyangbind cannot build module that pyang has found errors with.
Here is the models/test.yang file.
module test {
yang-version "1";
namespace "http://openconfig.net/yang/test";
prefix "test";
import openconfig-routing-policy { prefix "oc-rpol"; }
organization "OpenConfig working group";
contact
"OpenConfig working group
www.openconfig.net";
description
"This module is a test";
revision 2017-12-21 {
description
"Initial revision";
reference "TBD";
}
container device {
uses oc-rpol:routing-policy-top;
}
}
Is this behavior expected? I am trying to make a larger graph of our network and I want to apply the openconfig modules from an existing position in my tree with the 'uses' directive to get started on fleshing out the configs of devices.
This issue is stale because it has been open 180 days with no activity. If you wish to keep this issue active, please remove the stale label or add a comment, otherwise will be closed in 14 days.
When using pyang to compile the routing-policy.yang file I get success. But when I try to do so from another bare bones yang module referencing the same via 'uses' I get an error.
So while this works.
This does not.
Here is the models/test.yang file.
Is this behavior expected? I am trying to make a larger graph of our network and I want to apply the openconfig modules from an existing position in my tree with the 'uses' directive to get started on fleshing out the configs of devices.