[MDSAL-589] $YangModuleInfoImpl not generated Created: 14/Aug/20 Updated: 21/Oct/20 Resolved: 21/Oct/20 |
|
| Status: | Resolved |
| Project: | mdsal |
| Component/s: | Binding codegen |
| Affects Version/s: | None |
| Fix Version/s: | 6.0.4 |
| Type: | Bug | Priority: | Medium |
| Reporter: | Michal Banik | Assignee: | Robert Varga |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
When using module containing only extension(s), the $YangModuleInfoImpl.java class for this module is not generated. As a workaround, the extension module needs to contain at least one other element - It works when (at least) container or identity was added to module. module with extension defined:
module extension-model {
yang-version 1;
namespace "extension-model";
prefix "ex";
revision "2020-08-13" { }
extension custom-ex {
description ".....";
}
}
module where extension is used:
module main-model {
yang-version 1;
namespace "main-model";
prefix "main";
import extension-model { prefix "ex"; }
revision "2020-08-13" { }
container root-contaner {
leaf leaf1 {
type string;
ex:custom-ex;
}
}
}
for these it will not generate $YangModuleInfoImpl.java class file.
the $YangModuleInfoImpl.java class will be generated if extension model is updated by adding dummy container:
module extension-model {
yang-version 1;
namespace "extension-model";
prefix "ex";
revision "2020-08-13" { }
extension custom-ex {
description ".....";
}
container dummy {
// necessary element in only extensions model
}
}
Example models are shown also in gerrit change 92155 |
| Comments |
| Comment by Robert Varga [ 21/Sep/20 ] |
|
I believe this was fixed 6+ years ago, in 45bb1442df2e0d1a762cbb44e95580caf89e3b11. |
| Comment by Michal Banik [ 21/Oct/20 ] |
|
Hi Robert, I can confirm that it works for aluminium
closing |