Uploaded image for project: 'ONOS'
  1. ONOS
  2. ONOS-6450

YANG Compiler: Compilation failing in hierarchical grouping with augment.

    XMLWordPrintable

    Details

    • Type: Story
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Won't Fix
    • Affects Version/s: 1.10.0
    • Fix Version/s: None
    • Component/s: YangCompiler
    • Labels:
      None

      Description

      Marcs-MacBook-Pro:models marc$ buck build //models/openroadm:onos-models-openroadm
      Not using buckd because NO_BUCKD is set.
      BUILD FAILED: //models/openroadm:onos-models-openroadm-yang#srcs failed on step yang-compile with an exception:
      YANG file error: Either "data-def-substatements" or "case" should be present in "augment "/org-openroadm-device:org-openroadm-device/org-openroadm-device:interface"".
      org.onosproject.yang.compiler.api.YangCompilerException: YANG file error: Either "data-def-substatements" or "case" should be present in "augment "/org-openroadm-device:org-openroadm-device/org-openroadm-device:interface"".
      at org.onosproject.yang.compiler.tool.YangCompilerManager.processYangFiles(YangCompilerManager.java:229)
      at org.onosproject.yang.compiler.tool.YangCompilerManager.compileYangFiles(YangCompilerManager.java:99)
      at org.onosproject.yang.compiler.plugin.buck.YangGenerator.execute(YangGenerator.java:93)
      at org.onosproject.yang.compiler.plugin.buck.YangStep.execute(YangStep.java:71)
      at com.facebook.buck.step.DefaultStepRunner.runStepForBuildTarget(DefaultStepRunner.java:62)
      at com.facebook.buck.rules.CachingBuildEngine.executeCommandsNowThatDepsAreBuilt(CachingBuildEngine.java:1240)
      at com.facebook.buck.rules.CachingBuildEngine.lambda$null$0(CachingBuildEngine.java:320)
      at com.facebook.buck.rules.CachingBuildEngine$$Lambda$170/557680903.call(Unknown Source)
      at com.facebook.buck.util.concurrent.WeightedListeningExecutorService.lambda$submitWithSemaphore$0(WeightedListeningExecutorService.java:77)
      at com.facebook.buck.util.concurrent.WeightedListeningExecutorService$$Lambda$74/723602324.apply(Unknown Source)
      at com.google.common.util.concurrent.Futures$AsyncChainingFuture.doTransform(Futures.java:1442)
      at com.google.common.util.concurrent.Futures$AsyncChainingFuture.doTransform(Futures.java:1433)
      at com.google.common.util.concurrent.Futures$AbstractChainingFuture.run(Futures.java:1408)
      at com.google.common.util.concurrent.Futures$2$1.run(Futures.java:1177)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      at java.lang.Thread.run(Thread.java:745)
      Caused by: org.onosproject.yang.compiler.parser.exceptions.ParserException: YANG file error: Either "data-def-substatements" or "case" should be present in "augment "/org-openroadm-device:org-openroadm-device/org-openroadm-device:interface"".
      at org.onosproject.yang.compiler.parser.impl.parserutils.ListenerValidation.validateCardinalityEitherOne(ListenerValidation.java:236)
      at org.onosproject.yang.compiler.parser.impl.listeners.AugmentListener.valSubStatCardinality(AugmentListener.java:187)
      at org.onosproject.yang.compiler.parser.impl.listeners.AugmentListener.processAugmentEntry(AugmentListener.java:113)
      at org.onosproject.yang.compiler.parser.impl.TreeWalkListener.enterAugmentStatement(TreeWalkListener.java:1422)
      at org.onosproject.yang.compiler.parser.antlrgencode.GeneratedYangParser$AugmentStatementContext.enterRule(GeneratedYangParser.java:14745)
      at org.antlr.v4.runtime.tree.ParseTreeWalker.enterRule(ParseTreeWalker.java:66)
      at org.antlr.v4.runtime.tree.ParseTreeWalker.walk(ParseTreeWalker.java:49)
      at org.antlr.v4.runtime.tree.ParseTreeWalker.walk(ParseTreeWalker.java:52)
      at org.antlr.v4.runtime.tree.ParseTreeWalker.walk(ParseTreeWalker.java:52)
      at org.antlr.v4.runtime.tree.ParseTreeWalker.walk(ParseTreeWalker.java:52)
      at org.antlr.v4.runtime.tree.ParseTreeWalker.walk(ParseTreeWalker.java:52)
      at org.onosproject.yang.compiler.parser.impl.YangUtilsParserManager.getDataModel(YangUtilsParserManager.java:92)
      at org.onosproject.yang.compiler.tool.YangCompilerManager.parseYangFileInfoSet(YangCompilerManager.java:339)
      at org.onosproject.yang.compiler.tool.YangCompilerManager.processYangFiles(YangCompilerManager.java:210)
      ... 16 more

      [-] PROCESSING BUCK FILES...FINISHED 1.4s [100%] 🐳 New buck daemon
      [-] DOWNLOADING... (0.00 B/S AVG, TOTAL: 0.00 B, 0 Artifacts)
      [-] BUILDING...FINISHED 3.0s [100%] (13/16 JOBS, 0 UPDATED, 0 [0.0%] CACHE MISS)

        Attachments

        # Subject Branch Project Status CR V

          Activity

            People

            Assignee:
            Vidyashree-Huawei Vidyashree Rama
            Reporter:
            gauravagrawal Gaurav Agrawal
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: