Using tailf:cli-suppress-list-no in a leaf-list node

Hi,

I want to use the tailf:cli-suppress-list-no extension in a leaf-list to make it impossible to delete the whole leaf-list by entering no foo. Instead it should only be possible to delete individual instances by entering no foo <instance>. But it is still possible to delete the whole list even with this extension.

As workaround, using the extension in a list node gives following output from CLI, just as desired:

host(config)# no baz 
-------------------- ^
syntax error: incomplete path

According to the ConfD User Guide, this extension brings this feature for both list and leaf-list. Am I missing something or is this a bug?

Thanks for your help!

See my example nodes:

leaf-list foo {
    tailf:cli-suppress-list-no;
    type string;
}

list baz {
    key index;
    tailf:cli-suppress-mode;
    tailf:cli-suppress-list-no;    
    
    leaf index {
        type string;
    }
}

It will work according to your requirement if you add the tailf:cli-incomplete-no YANG annotation to your leaf-list as follows:

leaf-list foo {
    tailf:cli-incomplete-no;
    tailf:cli-suppress-list-no;
    type string;
}
1 Like

It seems that tailf:cli-suppress-list-no doesn’t impact leaf-list at all because it works also with just:

leaf-list foo {
    tailf:cli-incomplete-no;
    type string;
}

However, thank you very much for helping me solve this.