Re: [Netconf] Invalid when-stmts in yang-push

Kent Watsen <kwatsen@juniper.net> Mon, 07 January 2019 20:23 UTC

Return-Path: <kwatsen@juniper.net>
X-Original-To: netconf@ietfa.amsl.com
Delivered-To: netconf@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 2601212D4F2 for <netconf@ietfa.amsl.com>; Mon, 7 Jan 2019 12:23:53 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.765
X-Spam-Level:
X-Spam-Status: No, score=-2.765 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.065, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=juniper.net
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Y26fCYT4m2iA for <netconf@ietfa.amsl.com>; Mon, 7 Jan 2019 12:23:50 -0800 (PST)
Received: from mx0b-00273201.pphosted.com (mx0a-00273201.pphosted.com [208.84.65.16]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id DBE5912008A for <netconf@ietf.org>; Mon, 7 Jan 2019 12:23:49 -0800 (PST)
Received: from pps.filterd (m0108157.ppops.net [127.0.0.1]) by mx0a-00273201.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x07KM03i017891; Mon, 7 Jan 2019 12:23:44 -0800
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=juniper.net; h=from : to : subject : date : message-id : references : in-reply-to : content-type : mime-version; s=PPS1017; bh=OPavGDsYNwGA8/mtJPYDzoCe/5XCDHVAocMXmbXGlow=; b=r1hopya0hqWrsc62gL3ahu0+CcDEg1El50H1DvPVyDQVpvMwRMRJIyBGn17QOdUwTcv4 v06KLBHlAF/B/Vg5g+uO7LiP8mUgTbh7CdadT2X+RX94PXmMEAXAduk1KhR91/Sh/wuj oJfPa2zZkeJjA6gnmjWrfhJWQRQYQ5J+cWj+orGwBxXGuulSrwNFYNztHw4H3X3MkXiz Q541qs+NjuWw0978G8J2bTlMpXTnQNbYSJCGfDBbOh/+RWbln02oRS1m/UA6/WEHOc/d osvfk2pgsfUScX/iaf+DyDGZkpdeqis8d/C9MUDzaE2/MsEQw81zcRFSH79ljMd4P4pP 5Q==
Received: from nam05-by2-obe.outbound.protection.outlook.com (mail-by2nam05lp2053.outbound.protection.outlook.com [104.47.50.53]) by mx0a-00273201.pphosted.com with ESMTP id 2pv4pngt9n-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Mon, 07 Jan 2019 12:23:44 -0800
Received: from DM6PR05MB4665.namprd05.prod.outlook.com (20.176.109.202) by DM6PR05MB5177.namprd05.prod.outlook.com (20.177.223.161) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1516.10; Mon, 7 Jan 2019 20:23:42 +0000
Received: from DM6PR05MB4665.namprd05.prod.outlook.com ([fe80::c9e6:54c9:90c8:211e]) by DM6PR05MB4665.namprd05.prod.outlook.com ([fe80::c9e6:54c9:90c8:211e%2]) with mapi id 15.20.1516.010; Mon, 7 Jan 2019 20:23:42 +0000
From: Kent Watsen <kwatsen@juniper.net>
To: "Eric Voit (evoit)" <evoit@cisco.com>, Andy Bierman <andy@yumaworks.com>, Netconf <netconf@ietf.org>, Alexander Clemm <alexander.clemm@huawei.com>
Thread-Topic: [Netconf] Invalid when-stmts in yang-push
Thread-Index: AQHUh2x8oOOmxCDRQ0yQiBTrSu06mKVlzmOAgAF+SoCAAAGcgIA83M6A
Date: Mon, 07 Jan 2019 20:23:42 +0000
Message-ID: <B01D40F7-31A3-42C7-9F4C-8C4373ED5F1E@juniper.net>
References: <CABCOCHRAa91=S2fx7+gZZwZiNq5byC7HSoR4Sm+Ogk7GMKK0Vg@mail.gmail.com> <CABCOCHTEQ9B31S9V6Kv+XuE4ZRNXNx1wQeYeJ06pvJZhb87taA@mail.gmail.com> <CABCOCHSBoXYtUcOPJqNkUvzx2GFX9w5=-N1J66sz4m8S=HFFtg@mail.gmail.com> <47f53bf89c404a04a837ea5875b04990@XCH-RTP-013.cisco.com>
In-Reply-To: <47f53bf89c404a04a837ea5875b04990@XCH-RTP-013.cisco.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
user-agent: Microsoft-MacOutlook/10.10.5.181209
x-originating-ip: [66.129.241.12]
x-ms-publictraffictype: Email
x-microsoft-exchange-diagnostics: 1; DM6PR05MB5177; 6:GVIuOx8OBPJeFPW9773sWNBMFKdDSMUYI6F1kLOXDrxWHOqjzk6s/JXJdF61j6r0IkxH5EfREbzHlVq+PYfUMqF2TkQ7Swc1e0NpqmPDZD6mlR9AlRk688A/j1Ng8H3wKWSKhuAUdWZiQbnjOQIZuz9D48TMg+ZNy/1nwM21MwVnc6dTPuVU/QR4+uuK1AlhpBcMtPnIxXTLvjJrU285nx5SBHbb9vKCRk3Ay1+EVpJHLbfc/NJCi8Uh0+dkS1NbBiknssOItS1BrQ1la34ouDyP2PtDi7bGyqMzE14NXdIJXDXfa/8yX0XNGzxHzwZePlUrsflfGOxRLx0uJEY9bEGkY2EjXA+IRBn+7EiZwFlhDeVIMtYtIHxGg3zwNIp5BpzfbaHnypht6ViTeuu9VjikfMtVcQ0sAM+DR8UGRB70+uJjb2tyKa25aBCuvFnoDS5/6C0feYoYzNWHHtMi7g==; 5:xscYZKQmkzmCSPm+WfDQ07d2O4Zc+xw5KX1W+s+1gPSTPWlg8cV8JPt41W5rsEfZEwzZJE0O/kTQ61Y8l6Ml95+EClj1AlyRk1pqOW6ez/mjbfcnwmZBn0ehRML0qpIMxbRdgyKU0QgJehLemqXFkM+AhN/euR4jQrIUIurq8DoKcsI4E7FAPiSaTmB9e7IXpBIkmQjeFRy+tSVGuzmB3g==; 7:z06PeRGQBeMM3nZvlJED1PQWlMQnXBkTVQN7H0OFi0tfLmAlO728xwwrbA25pvNprCaH7eJ/fEX97FIGebjv/lgFH3qUNvhv7KCOygnvL2bIlm+ngzCrxA9zAOCd0QATp4M1CxCDf+p4Bw0rFju4gQ==
x-ms-exchange-antispam-srfa-diagnostics: SOS;
x-ms-office365-filtering-correlation-id: f47b0e59-3d02-4de9-1a3b-08d674de0475
x-ms-office365-filtering-ht: Tenant
x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600109)(711020)(4618075)(2017052603328)(7153060)(7193020); SRVR:DM6PR05MB5177;
x-ms-traffictypediagnostic: DM6PR05MB5177:
x-microsoft-antispam-prvs: <DM6PR05MB5177E1618620B1CAEE7132E5A5890@DM6PR05MB5177.namprd05.prod.outlook.com>
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(3230021)(908002)(999002)(5005026)(6040522)(8220060)(2401047)(8121501046)(3002001)(3231475)(944501520)(52105112)(93006095)(93001095)(10201501046)(6055026)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123564045)(20161123562045)(20161123558120)(20161123560045)(201708071742011)(7699051)(76991095); SRVR:DM6PR05MB5177; BCL:0; PCL:0; RULEID:; SRVR:DM6PR05MB5177;
x-forefront-prvs: 0910AAF391
x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(376002)(366004)(346002)(136003)(396003)(39860400002)(199004)(189003)(8936002)(9326002)(71200400001)(8676002)(81166006)(81156014)(86362001)(93886005)(53936002)(2906002)(105586002)(58126008)(6246003)(110136005)(236005)(97736004)(316002)(3846002)(99286004)(14454004)(36756003)(106356001)(6116002)(6436002)(11346002)(486006)(6506007)(2616005)(446003)(476003)(229853002)(186003)(6486002)(102836004)(6346003)(54896002)(26005)(6306002)(33656002)(82746002)(6512007)(478600001)(256004)(14444005)(7736002)(53546011)(76176011)(25786009)(66066001)(83716004)(5660300001)(71190400001)(68736007); DIR:OUT; SFP:1102; SCL:1; SRVR:DM6PR05MB5177; H:DM6PR05MB4665.namprd05.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1;
received-spf: None (protection.outlook.com: juniper.net does not designate permitted sender hosts)
x-ms-exchange-senderadcheck: 1
x-microsoft-antispam-message-info: uJ+3EknjAIK07gS+8JMe/bEcurvteCBBuQZpfOkI+YNfxdsIC5lbMqaG7ccq5q5gpkNMmSXEDNcJr7kaKyzyFoB8llNrglwEsEzJfAEPAa0RveKr/ZRbSj+lyX+xX6sqrPc1AuQK1ZS37k1kc6FLJrNas8MLJx16xwJq2oZaltLdK3AyDCVomczv/491Llv/AlJ2tt/VSL49ONwxR6yBeMhUUbhaVdkSA9+4Cq/9aiknMveOAjMXGhjJqeNY840spc0YekcsafONCccNvMGTNMzKcIx2TT4e11rzWw4bCKpyRH2cyMYXJzMTG57IWcwA
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: multipart/alternative; boundary="_000_B01D40F731A342C79F4C8C4373ED5F1Ejunipernet_"
MIME-Version: 1.0
X-OriginatorOrg: juniper.net
X-MS-Exchange-CrossTenant-Network-Message-Id: f47b0e59-3d02-4de9-1a3b-08d674de0475
X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Jan 2019 20:23:42.4708 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: bea78b3c-4cdb-4130-854a-1d193232e5f4
X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR05MB5177
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-01-07_09:, , signatures=0
X-Proofpoint-Spam-Details: rule=outbound_spam_notspam policy=outbound_spam score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1901070169
Archived-At: <https://mailarchive.ietf.org/arch/msg/netconf/hDGvIM5Mvkj8QgVXHWX7onQr1H8>
Subject: Re: [Netconf] Invalid when-stmts in yang-push
X-BeenThere: netconf@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Network Configuration WG mailing list <netconf.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/netconf>, <mailto:netconf-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/netconf/>
List-Post: <mailto:netconf@ietf.org>
List-Help: <mailto:netconf-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/netconf>, <mailto:netconf-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 07 Jan 2019 20:23:53 -0000

Hi Alex,

Have you had a chance to look at this issue yet?  The assigned YANG Doctor says that they immediately stumbled on this error and is waiting for an update with a valid module before proceeding with the review.

PS: All authors should integrate the validation of YANG modules and examples as part of the `xml2rfc` build process.  Also recommended is dynamic generation of the tree diagrams, and execution of the `idnits` tool.  The time it takes to set this up in the beginning is easily recovered over the course of the draft’s lifetime.  Remember, it’s not just your time, but also the time of everyone else that runs into these issues, and then the slow restart times (this thread is an example of that).

Kent // shepherd/chair


On 11/29/18, 4:58 PM, "Netconf on behalf of Eric Voit (evoit)" <netconf-bounces@ietf.org<mailto:netconf-bounces@ietf.org> on behalf of evoit@cisco.com<mailto:evoit@cisco.com>> wrote:

Thanks Andy.   Adding Alex to make the change.

Eric

From: Netconf <netconf-bounces@ietf.org> On Behalf Of Andy Bierman
Sent: Thursday, November 29, 2018 4:52 PM
To: Netconf <netconf@ietf.org>
Subject: Re: [Netconf] Invalid when-stmts in yang-push

Hi,

I think this diff fixes the yang-push module.
It looks like the augment to modify-subscription used the wrong grouping
because the 'datastore' leaf was missing.

365c365
<       when "../sn:target/yp:datastore";
---
>       when "yp:datastore";
572c572
<     when "sn:target/yp:datastore";
---
>     when "yp:datastore";
616c616
<     when "sn:target/yp:datastore";
---
>     when "yp:datastore";
632c632
<       uses selection-filter-objects;
---
>       uses datastore-criteria;
816c816
<     when "sn:target/yp:datastore";
---
>     when "yp:datastore";


Andy



On Wed, Nov 28, 2018 at 3:03 PM Andy Bierman <andy@yumaworks.com<mailto:andy@yumaworks.com>> wrote:

On Wed, Nov 28, 2018 at 2:48 PM Andy Bierman <andy@yumaworks.com<mailto:andy@yumaworks.com>> wrote:
Hi,

During implementation of yang-push-20 our developer found that
the when-stmts for establish-subscription are always false.


E.g. line 365:
    choice update-trigger {
      when "../sn:target/yp:datastore";

The node 'target' is a choice. The node 'datastore' is a case.
Since the when-stmt is looking for data nodes not schema nodes,
the node-set is always empty.


There are 4 occurrences:

Warning: no child node 'ietf-subscribed-notifications:target' found for parent 'ietf-subscribed-notifications:subscriptions'
XPath: ../sn:target/yp:datastore
ietf-yang-push.yang:365.15: warning(1032): no child node available

Warning: no child node 'ietf-subscribed-notifications:target' found for parent 'ietf-subscribed-notifications:input'
XPath: sn:target/yp:datastore
ietf-yang-push.yang:572.10: warning(1032): no child node available

Warning: no child node 'ietf-subscribed-notifications:target' found for parent 'ietf-subscribed-notifications:input'
XPath: sn:target/yp:datastore
ietf-yang-push.yang:616.10: warning(1032): no child node available

Warning: no child node 'ietf-subscribed-notifications:target' found for parent 'ietf-subscribed-notifications:subscription'
XPath: sn:target/yp:datastore
ietf-yang-push.yang:816.10: warning(1032): no child node available



pyang is also reporting these warnings:

ietf-yang-push.yang:365: warning: XPath for "../sn:target/yp:datastore" does not exist
ietf-yang-push.yang:572: warning: XPath for "sn:target/yp:datastore" does not exist
ietf-yang-push.yang:616: warning: XPath for "sn:target/yp:datastore" does not exist
ietf-yang-push.yang:816: warning: XPath for "sn:target/yp:datastore" does not exist


Andy