All,

While addressed to me, I was just seeking clarification on the ask.  Now that 
it is understood, could someone take a stab at a reply? 

FWIW, I don't have working experience with `deviate` and thus rather not reply.

Kent


> On Oct 24, 2019, at 9:44 AM, Balázs Lengyel 
> <[email protected]> wrote:
> 
> Hello Kent,
> As IMO practically all tools are misbehaving I would like a confirmation that 
> my interpretation of the differences between deviate add and deviate replace 
> are correct.  After that I will start reporting the issues to the tools.
> Regards Balazs
>  
> From: Kent Watsen <[email protected] <mailto:[email protected]>> 
> Sent: 2019. október 22., kedd 16:37
> To: Balázs Lengyel <[email protected] 
> <mailto:[email protected]>>
> Cc: [email protected] <mailto:[email protected]>; Mark Hollmann 
> <[email protected] <mailto:[email protected]>>; Edvardas 
> Lasauskas <[email protected] 
> <mailto:[email protected]>>
> Subject: Re: [netmod] Default statements and deviate add/replace
>  
> Hi Balazs,
>  
> Is this for the NETMOD list, or should bugs be filed against the misbehaving 
> tools?
>  
> Kent
>  
> 
> 
> On Oct 22, 2019, at 6:56 AM, Balázs Lengyel 
> <[email protected] 
> <mailto:[email protected]>> wrote:
>  
> Hello, 
> I tried testing the following statements:
>  
>   deviation /nacm:nacm/nacm:enable-nacm {
>     deviate add {
>       config false;     } }
>                 
>   deviation /nacm:nacm/nacm:rule-list {
>     deviate add {
>       min-elements 1;     }  }
>  
> In nacm both the config and the min-elements are absent, so their default 
> meaning is true. I actually tried both add and replace in deviate.
> I got rather confusing results whether the add/replace variant of deviate 
> should be accepted or rejected because the property already exists or does 
> not yet exist.
>  
> Pyang 2.0.2 locally:
> Config=false                       add-NOK              replace-OK
> Min-elements=1              add-OK                 replace-NOK
>  
> YANG-Validator  pyang 2.0 & confdc
> Config=false                       add-OK                 replace-OK
> Min-elements=1              add-OK                 replace-NOK
>  
> YANG-Validator yanglint
> Config=false                       add-OK                 replace-OK
> Min-elements=1              add-OK                 replace-OK
>  
> IMHO the tools should always check the property, so even if the statement is 
> not present the properties config=false and min-elements=0 ARE present. So 
> add should be rejected and replace accepted. 
>  
> Regards Balazs
>  
> -- 
> Balazs Lengyel                    Senior Specialist                       
> Ericsson Hungary Ltd. 
> Mobile: +36-70-330-7909              email: [email protected] 
> <mailto:[email protected]>
>  
> _______________________________________________
> netmod mailing list
> [email protected] <mailto:[email protected]>
> https://www.ietf.org/mailman/listinfo/netmod 
> <https://www.ietf.org/mailman/listinfo/netmod>
>  
> _______________________________________________
> netmod mailing list
> [email protected] <mailto:[email protected]>
> https://www.ietf.org/mailman/listinfo/netmod 
> <https://www.ietf.org/mailman/listinfo/netmod>
_______________________________________________
netmod mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/netmod

Reply via email to