Subject: Re: [Lime] draft-ietf-lime-yang-oam-model-07.txt: YANG compilation error

From: Benoit Claise <[email-masked]>
Date: Wed, 7 Sep 2016 15:36:56 +0200

Dear authors,

Please solve the compilation issue with your draft.

I've been adding a new column to the report at 
http://www.claise.be/IETFYANGPageCompilation.html, where from you can 
download the extracted YANG module.
Lately, I received some concerns about the line number from the pyang 
output that could not easily match to the YANG module line number.
Indeed the pyang error line number is the one from the YANG module and 
not the IETF draft. This is specifically a concern with xpath issues.
On top of that, some people use rfcstrip as opposed to xym.py to extract 
the YANG modules from IETF draft.

The error for your draft is:

    ietf-conn-oam.yang:351: error: the node 'MD-name-format' from module
    'ietf-conn-oam' is not found
    ietf-conn-oam.yang:351: error: the node 'name-format-null' from
    module 'ietf-conn-oam' (in node 'MD-name-null' from 'ietf-conn-oam')
    is not found
    ietf-conn-oam.yang:391: error: the node 'MA-name-format' from module
    'ietf-conn-oam' (in node 'domain' from 'ietf-conn-oam') is not found
    ietf-conn-oam.yang:391: error: the node 'name-format-null' from
    module 'ietf-conn-oam' (in node 'MA-name-null' from 'ietf-conn-oam')
    is not found

Downloading the YANG, I confirm that this is a xpath issue.

     choice MD-name {
       case MD-name-null {
         leaf MD-name-null {
         when "../../../MD-name-format = name-format-null" 
{                     <= line 351
         description
         "MD name format is equal to null format.";
         }
         type empty;
         description
         "MD name Null.";
         }
       }
       description
         "MD name.";
     }

   grouping MA-name {
     description
       "MA name";
     leaf MA-name-format {
       type identityref {
         base name-format;
       }
       description
         "Ma name format";
     }
     choice MA-name {
      case MA-name-null {
       leaf MA-name-null {
        when "../../../MA-name-format = name-format-null" 
{               <= line 391
        description
          "MA";
       }
         type empty;
         description
         "empty";
         }
       }
       description
         "MA name";
     }
   }

Regards, Benoit
> Dear authors,
>
> Part of the IETF hackathon today, I integrated confdc , as a second 
> YANG module compiler, in 
> http://www.claise.be/IETFYANGPageCompilation.html. Reason? For 
> example, confdc validates xpath while pyang doesn't.
> And confdc found an issue with your draft, which is now flagged as 
> failing the YANG compilation.
> Please correct this issue.
> Note: you're not alone, look at the green dip today on green graph 
> <http://claise.be/IETFYANGPageCompilation.png>!
>
> During the hackathon today, Carl Moberg also integrated the confdc 
> output in his www.yangalidtor.com.
> This might help you.
>
> Regards, Benoit
>
>
> _______________________________________________
> Lime mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/lime