<!-- 
RSS generated by JIRA (8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d) at Wed Feb 07 20:56:28 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>OpenDaylight JIRA</title>
    <link>https://jira.opendaylight.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>8.20.10</version>
        <build-number>820010</build-number>
        <build-date>22-06-2022</build-date>
    </build-info>


<item>
            <title>[YANGTOOLS-1545] Min/max-elements are not enforced for wrapped elements in container</title>
                <link>https://jira.opendaylight.org/browse/YANGTOOLS-1545</link>
                <project id="10188" key="YANGTOOLS">yangtools</project>
                    <description>&lt;p&gt;Currently, it is possible to create a list/leaf-list with min-elements and max-element violations if those elements are wrapped with a container in the payload.&lt;/p&gt;

&lt;p&gt;For example in this model:&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
module test-container-childs {
&#160; &#160; namespace &lt;span class=&quot;code-quote&quot;&gt;&quot;http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child&quot;&lt;/span&gt;;
&lt;/span&gt;&#160; &#160; prefix &lt;span class=&quot;code-quote&quot;&gt;&quot;tcc&quot;&lt;/span&gt;;
&#160; &#160; revision 2023-09-28;

    container root-container {
&#160; &#160; &#160; &#160; container nested-container {
&#160; &#160; &#160; &#160; &#160; &#160; list mandatory-list {
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; min-elements 1;
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; max-elements 3;
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; key id;
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; leaf id {
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; type uint32;
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; }
&#160; &#160; &#160; &#160; &#160; &#160; }
&#160; &#160; &#160; &#160; }
&#160; &#160; }
}&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;It is allowed to create 0 list resources or more than 3, if the list `mandatory-list` is wrapped with &quot;nested-container&quot; in the payload:&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
{
&#160; &#160; &lt;span class=&quot;code-quote&quot;&gt;&quot;nested-container&quot;&lt;/span&gt;: {
&#160; &#160; &#160; &#160; &lt;span class=&quot;code-quote&quot;&gt;&quot;mandatory-list&quot;&lt;/span&gt;: []
&#160; &#160; }
}&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;The same issue is present for the leaf-list element.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;This issue was already reported before, and resolved:&lt;br/&gt;
&lt;a href=&quot;https://jira.opendaylight.org/browse/YANGTOOLS-776&quot; class=&quot;external-link&quot; rel=&quot;nofollow&quot;&gt;https://jira.opendaylight.org/browse/YANGTOOLS-776&lt;/a&gt;&lt;/p&gt;</description>
                <environment></environment>
        <key id="37425">YANGTOOLS-1545</key>
            <summary>Min/max-elements are not enforced for wrapped elements in container</summary>
                <type id="10104" iconUrl="https://jira.opendaylight.org/secure/viewavatar?size=xsmall&amp;avatarId=10303&amp;avatarType=issuetype">Bug</type>
                                            <priority id="3" iconUrl="https://jira.opendaylight.org/images/icons/priorities/major.svg">Medium</priority>
                        <status id="1" iconUrl="https://jira.opendaylight.org/images/icons/statuses/open.png" description="The issue is open and ready for the assignee to start work on it.">Open</status>
                    <statusCategory id="2" key="new" colorName="blue-gray"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="ivanhrasko">Ivan Hrasko</assignee>
                                    <reporter username="PeterSuna">Peter Suna</reporter>
                        <labels>
                            <label>pt</label>
                    </labels>
                <created>Mon, 2 Oct 2023 16:05:41 +0000</created>
                <updated>Fri, 6 Oct 2023 08:16:38 +0000</updated>
                                            <version>11.0.2</version>
                                                        <due></due>
                            <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="72630" author="rovarga" created="Tue, 3 Oct 2023 07:04:03 +0000"  >&lt;p&gt;So &quot;create&quot; as in normalized node structure?&lt;br/&gt;
Or &quot;create&quot; as in the contents of DataTree?&lt;/p&gt;</comment>
                            <comment id="72634" author="petersuna" created="Wed, 4 Oct 2023 15:45:24 +0000"  >&lt;p&gt;It is possible to write into the task model using the method.&lt;br/&gt;
&lt;a href=&quot;https://github.com/opendaylight/mdsal/blob/3211a81a215cdb2daa4bdfe07ace257205f34b72/dom/mdsal-dom-spi/src/main/java/org/opendaylight/mdsal/dom/spi/store/SnapshotBackedWriteTransaction.java#L72&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;SnapshotBackedWriteTransaction.write(path, normalizedNode)&lt;/a&gt;&lt;br/&gt;
Data:&lt;br/&gt;
path -&amp;gt; /(&lt;a href=&quot;http://example.com/test/container/child?revision=2023-09-28)root-container/nested-container&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://example.com/test/container/child?revision=2023-09-28)root-container/nested-container&lt;/a&gt;&lt;br/&gt;
normalizedNode -&amp;gt;&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;
ImmutableContainerNode{
&#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)nested-container,
&lt;/span&gt;&#160; body=[
&#160; &#160; ImmutableMapNode{
&#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)mandatory-list,
&lt;/span&gt;&#160; &#160; &#160; body=[
&#160; &#160; &#160; &#160; ImmutableMapEntryNode{
&#160; &#160; &#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)mandatory-list[{(http://example.com/test/container/child?revision=2023-09-28)id=1}],
&lt;/span&gt;&#160; &#160; &#160; &#160; &#160; body=[
&#160; &#160; &#160; &#160; &#160; &#160; ImmutableLeafNode{
&#160; &#160; &#160; &#160; &#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)id,
&lt;/span&gt;&#160; &#160; &#160; &#160; &#160; &#160; &#160; body=1
&#160; &#160; &#160; &#160; &#160; &#160; }
&#160; &#160; &#160; &#160; &#160; ]
&#160; &#160; &#160; &#160; },
&#160; &#160; &#160; &#160; ImmutableMapEntryNode{
&#160; &#160; &#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)mandatory-list[{(http://example.com/test/container/child?revision=2023-09-28)id=2}],
&lt;/span&gt;&#160; &#160; &#160; &#160; &#160; body=[
&#160; &#160; &#160; &#160; &#160; &#160; ImmutableLeafNode{
&#160; &#160; &#160; &#160; &#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)id,
&lt;/span&gt;&#160; &#160; &#160; &#160; &#160; &#160; &#160; body=2
&#160; &#160; &#160; &#160; &#160; &#160; }
&#160; &#160; &#160; &#160; &#160; ]
&#160; &#160; &#160; &#160; },
&#160; &#160; &#160; &#160; ImmutableMapEntryNode{
&#160; &#160; &#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)mandatory-list[{(http://example.com/test/container/child?revision=2023-09-28)id=3}],
&lt;/span&gt;&#160; &#160; &#160; &#160; &#160; body=[
&#160; &#160; &#160; &#160; &#160; &#160; ImmutableLeafNode{
&#160; &#160; &#160; &#160; &#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)id,
&lt;/span&gt;&#160; &#160; &#160; &#160; &#160; &#160; &#160; body=3
&#160; &#160; &#160; &#160; &#160; &#160; }
&#160; &#160; &#160; &#160; &#160; ]
&#160; &#160; &#160; &#160; },
&#160; &#160; &#160; &#160; ImmutableMapEntryNode{
&#160; &#160; &#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)mandatory-list[{(http://example.com/test/container/child?revision=2023-09-28)id=4}],
&lt;/span&gt;&#160; &#160; &#160; &#160; &#160; body=[
&#160; &#160; &#160; &#160; &#160; &#160; ImmutableLeafNode{
&#160; &#160; &#160; &#160; &#160; &#160; &#160; name=(http:&lt;span class=&quot;code-comment&quot;&gt;//example.com/test/container/child?revision=2023-09-28)id,
&lt;/span&gt;&#160; &#160; &#160; &#160; &#160; &#160; &#160; body=4
&#160; &#160; &#160; &#160; &#160; &#160; }
&#160; &#160; &#160; &#160; &#160; ]
&#160; &#160; &#160; &#160; }
&#160; &#160; &#160; ]
&#160; &#160; }
&#160; ]
} &lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</comment>
                    </comments>
                    <attachments>
                            <attachment id="19211" name="Screenshot 2023-10-02 181339.png" size="50934" author="PeterSuna" created="Mon, 2 Oct 2023 16:15:27 +0000"/>
                            <attachment id="19212" name="Screenshot 2023-10-02 181427.png" size="63627" author="PeterSuna" created="Mon, 2 Oct 2023 16:15:27 +0000"/>
                            <attachment id="19213" name="Screenshot 2023-10-02 181444.png" size="57788" author="PeterSuna" created="Mon, 2 Oct 2023 16:15:27 +0000"/>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                            <customfield id="customfield_11400" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10000" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>0|i046n3:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                </customfields>
    </item>
</channel>
</rss>