[YANGTOOLS-650] Some imports are not exposed in Module.getImports Created: 22/Aug/16 Updated: 10/Apr/22 Resolved: 21/Oct/16 |
|
| Status: | Resolved |
| Project: | yangtools |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | Peter Verthez | Assignee: | Filip Gregor |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| External issue ID: | 6491 |
| Priority: | Low |
| Description |
|
If you have: module A { module B { // also without revision-date then the getImports() method on module B does not provide module A. It seems that this case is skipped over in AbstractEffectiveModule.resolveModuleImports(). I checked the RFC, and the situation seems legal, although it says:
But if there is only 1 revision of a module available, it seems logical to take that one. Workaround is to add a revision to the imported module, then it works (and it's also the logical thing to do, to add the revision). So the severity of this bug is low. |
| Comments |
| Comment by Martin Ciglan [ 30/Aug/16 ] |
|
Hi Peter It is legal, but there seems to be some inconsistency in processing between actual module A revision, where in that case, default one is used AND import of this module A, where methods providing collection of imports skip it. Even though, priority of this bug is low, it's on radar of YT devs. Thanks. Martin |
| Comment by Filip Gregor [ 20/Oct/16 ] |
|
proposed solution https://git.opendaylight.org/gerrit/#/c/47129/ |
| Comment by Robert Varga [ 21/Oct/16 ] |