Reject invalid InstanceIdentifiers

Description

The work done in https://lf-opendaylight.atlassian.net/browse/YANGTOOLS-435#icft=YANGTOOLS-435 ends up lowering safety guarantees about what streamChild() actually does.

This means that if we take a class generated for a top-level Notification or and RpcInput, defeating compile-time safeguards to create an InstanceIdentifier, the codec will happily generate a YangInstanceIdentifier containing the QName of that construct.

As such, the changes we've made in https://lf-opendaylight.atlassian.net/browse/YANGTOOLS-435#icft=YANGTOOLS-435 need to be undone and we need separate methods to enter into notification, rpc and action contexts, so that attempts at such misuse result in codec failure.

 

Activity

Show:
Done

Details

Assignee

Reporter

Components

Fix versions

Priority

Created February 21, 2022 at 1:52 PM
Updated February 22, 2022 at 9:18 PM
Resolved February 22, 2022 at 9:18 PM