[YANGTOOLS-770] Some augments are not being processed Created: 31/Mar/17 Updated: 10/Apr/22 Resolved: 10/Apr/17 |
|
| Status: | Resolved |
| Project: | yangtools |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | Peter Verthez | Assignee: | Peter Kajsa |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| Attachments: |
|
| External issue ID: | 8126 |
| Description |
|
We are currently using a snapshot of Carbon of March 11. Some augments in the model of one of our devices are not being picked up it seems. I have attached a minimal model to this ticket (which is the actual model, with all unnecessary parts removed, and with some types changed to string to avoid dragging in other models). The structure is as follows:
The parsing is successful, no errors are generated, but the dot1q-tag of that last augment is not returned in the parsed model. |
| Comments |
| Comment by Peter Verthez [ 31/Mar/17 ] |
|
Attachment augmentbug.tgz has been added with description: minimized model showing the bug |
| Comment by Peter Kajsa [ 03/Apr/17 ] |
|
There is an issue with mandatory nodes. Yang parser complains that "leaf tag-type" cannot be added by the augment because "leaf tag-type" is mandatory and augment target is in different module (please see attached log entry below). After quick investigation I think the leaf can be added, because "choice vlan-tag-match-type" is not mandatory node and in consequence "container match-criteria" is also not mandatory. So we need to fix the check of mandatory nodes in yang statement parser. We also need to increase severity of the log from debug to error. org.opendaylight.yangtools.yang.parser.stmt.rfc6020.AugmentStatementImpl - Failed to add augmentation /home/pkajsa/eclipse_workspace/yangtools/yang/yang-parser-impl/target-ide/test-classes/bugs/bug8126/bbf-frame-classification.yang:128:16 defined at /home/pkajsa/eclipse_workspace/yangtools/yang/yang-parser-impl/target-ide/test-classes/bugs/bug8126/bbf-sub-interface-tagging.yang:28:4 |
| Comment by Peter Kajsa [ 06/Apr/17 ] |