Details
Description
Given 2 yang models:
a.yang
module a {
namespace "urn:opendaylight:a";
prefix "a";
revision 2019-11-24 {
description "Initial revision";
}
grouping arg-path {
anyxml path {
description "ABC";
mandatory true;
}
}
}
b.yang
module b {
namespace "urn:opendaylight:b";
prefix "b";
import a { prefix "a"; }
revision 2019-11-24 {
description "Initial revision";
}
rpc rpc1 {
input {
uses a:arg-path { refine path { mandatory false; } }
}
}
}
Second model can't be compiled:
[ERROR] Failed to execute goal org.opendaylight.yangtools:yang-maven-plugin:3.0.4:generate-sources (binding) on project jsonrpc-test-model: Failed to process reactor ProcessorModuleReactor{sources=[RevisionSourceIdentifier [name=test-model@2016-11-17], RevisionSourceIdentifier [name=test-model-op-only@2018-03-05], RevisionSourceIdentifier [name=b@2019-11-24], RevisionSourceIdentifier [name=a@2019-11-24]], parser=org.opendaylight.yangtools.yang.parser.impl.YangParserImpl@3bbf1c0d}: Failed to assemble sources: Some of EFFECTIVE_MODEL modifiers for statements were not resolved. Refine target node Relative{path=[(urn:opendaylight:b?revision=2019-11-24)path]} not found. [at test-model/src/main/yang/b.yang:14:30] -> [Help 1]
Interestingly, refine target node is found when grouping is from same YANG model.