[netconf] yanglint errors for ietf-subscribed-notifications

Mahesh Jethanandani <mjethanandani@gmail.com> Fri, 13 March 2020 20:14 UTC

Return-Path: <mjethanandani@gmail.com>
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 0A8F73A0DAC; Fri, 13 Mar 2020 13:14:17 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.098
X-Spam-Level:
X-Spam-Status: No, score=-2.098 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
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 ezMvf1hEefoB; Fri, 13 Mar 2020 13:14:15 -0700 (PDT)
Received: from mail-pl1-x62e.google.com (mail-pl1-x62e.google.com [IPv6:2607:f8b0:4864:20::62e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 8CB5E3A0DA5; Fri, 13 Mar 2020 13:14:15 -0700 (PDT)
Received: by mail-pl1-x62e.google.com with SMTP id w12so4779159pll.13; Fri, 13 Mar 2020 13:14:15 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:mime-version:subject:message-id:date:to; bh=NK3dlyiWY/77F+xuoFh4C9fzI53x7uXMV5tkAyOsIGY=; b=VRGgOlzFUTEoXuXaui1vZ5htjObdwoV1fTsB9S8YVuukLl95fgbpm501vUctIgDlOb tNhp46S0pAXZDEu3K2M3khqsoP5Piq8L7z5WutoJu10F76CiRtr7Q+wXWbIXkHgiTd89 zD4q9phpYd7UT9LLckrm594DyoAPfrIsavvbRJ56LFNF4ATosVggFIjReQmjXESeylBu tf2Ll085/oEKhsSSw9hQvmqcECMeqIkbBxqgqi+CwdNIvwA6c+BygM/DIuJtWOU8mb6q 07ebWX/cBDyZEte6oaHczOJh9EPGISW92yt+guo/kKuUPjLkneH2kE4BtTcsKAJNc8kj RiwQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:subject:message-id:date:to; bh=NK3dlyiWY/77F+xuoFh4C9fzI53x7uXMV5tkAyOsIGY=; b=FxTFvYQG9gvAFiDfVECC5cQQPuf+wHzzGIH3BK+IUiHWkTGRsb8yxJ1TvqMbHWDNM2 nHfsd78Ywj70eSXW8++Tre9N+e8zn/N7uHUjVjPWeU0gddaqHc12C0oxpdhI4NBDe6QB MoqTneDZXzmZkjGCJych9yWAg3tFew+e64E/nwvLpnKNbu1/s4V7G06IV3XWInWzwMIn NzjFlXpTn+uLzn4fTqkZg9aVyylSvNtPEWo9HMPgmtdhbw2wdGY968c2zLCd1xeQArM6 muBFMlGRZnIRUQSoYJKnGLATxA0aFu7MeXzc4Ad/fU+4hIa8lG4P6O0LxAhdxkocRALU RTWA==
X-Gm-Message-State: ANhLgQ35W5i++C2PCVbVugwp2GqjoXL1fVVAqul6uTJIJrx2NOWOaobQ LdOZvFDeFWjduSFWw2ml2ZwTpojJ
X-Google-Smtp-Source: ADFU+vseNYqd6VANSO1Pa/ZF7+uXbLKVe2L+Dxe+hfEav1qtKIjyN3C55f5rz8Sx6Wj9FZElCVYIBw==
X-Received: by 2002:a17:90b:1983:: with SMTP id mv3mr11782406pjb.86.1584130454289; Fri, 13 Mar 2020 13:14:14 -0700 (PDT)
Received: from ?IPv6:2601:647:5600:5020:20a6:1027:cd80:bfca? ([2601:647:5600:5020:20a6:1027:cd80:bfca]) by smtp.gmail.com with ESMTPSA id o126sm11974031pfb.140.2020.03.13.13.14.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Mar 2020 13:14:13 -0700 (PDT)
From: Mahesh Jethanandani <mjethanandani@gmail.com>
Content-Type: multipart/alternative; boundary="Apple-Mail=_53AF3495-8FFF-4096-AA4A-0E3812C935DA"
Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.1\))
Message-Id: <E3909A5A-FACB-4A77-B57A-21E71C01436E@gmail.com>
Date: Fri, 13 Mar 2020 13:14:11 -0700
To: Netconf <netconf@ietf.org>, netmod@ietf.org
X-Mailer: Apple Mail (2.3445.9.1)
Archived-At: <https://mailarchive.ietf.org/arch/msg/netconf/U4Nd_zG96gbjUClqK2ZDDoCwCVg>
Subject: [netconf] yanglint errors for ietf-subscribed-notifications
X-BeenThere: netconf@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: NETCONF WG 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: Fri, 13 Mar 2020 20:14:17 -0000

As I mentioned in the other thread, I am seeing errors while trying to use yanglint to validate examples for modules that import ietf-subscribed-notifications. I see it with ietf-notification-capabilities and with my own draft ietf-https-notif. These errors do not appear with confd. 

Using ietf-notification-capabilites and the first example in the -12 version of the draft which I call examples-notification-capabilities-1.xml, and released models for ietf-yang-push and ietf-subscribed-notifications, I see two issues. The first one related to the statement 'required-instance’ in ietf-subscribed-notifications is discussed on the other thread, and I do not want to repeat it here. If I comment out the only instance of ‘required-instance’ in the module, I run into more errors:

bash-3.2$ yanglint -s -i -t auto -p /Volumes/External/git/iana/yang-parameters/ ietf-system-capabilities@2020-03-08.yang ietf-notification-capabilities@2020-03-09.yang examples-notification-capabilities-1.xml 
err : The leafref leaf is config but refers to a non-config leaf. (/ietf-subscribed-notifications:subscriptions/subscription/target/stream/stream)
err : Invalid value "subscription-policy" of "uses". (/ietf-subscribed-notifications:subscriptions/subscription/subscription-policy)
err : Copying data from grouping failed. (/ietf-subscribed-notifications:subscriptions/subscription/subscription-policy)
err : Module "ietf-subscribed-notifications" parsing failed.
err : Importing "ietf-subscribed-notifications" module into "ietf-yang-push" failed.
err : Module "ietf-yang-push" parsing failed.
err : Importing "ietf-yang-push" module into "ietf-notification-capabilities" failed.
err : Module "ietf-notification-capabilities" parsing failed.

While pyang gives the following error:

bash-3.2$  pyang -f tree ietf-subscribed-notifications@2019-09-09.yang > ietf-subscribed-notifications@2019-09-09-tree.txt
ietf-subscribed-notifications@2019-09-09.yang:381: error: the path for stream is config but refers to a non-config leaf "name" defined at ietf-subscribed-notifications@2019-09-09.yang:1046

Have other encountered this error? If we agree this is an error, is there a -bis to fix this?

Thanks.

Mahesh Jethanandani
mjethanandani@gmail.com