-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
leafref broken for cross module leaf references ? #31
Comments
Hi Amit, I actually don't think that is valid YANG schema? From the context of the module bar, it can use module foo's exported grouping, typedef, etc. it can also augment the foo module. But I don't think it can access data tree elements from module foo. At least that's how I understood the spec. If there's public examples of how this should be possible, please share the reference. |
Sorry, you're right! I didn't realize you should be allowed to go outside your current module for leafref! Ok will need to fix. :-)
|
This should be addressed but I haven't verified. Here's an example of how to test: Yang = require 'yang-js'
store = new Yang.Store 'test'
store.import <schema or model>
store.import <schema or model>
console.log store.data.valueOf() Basically, you can It'd be great if you can give it a try with the latest |
@ramukima - were you able to confirm/verify the cross-module leafref functionality? |
I tested it with petstore example and I could see it work. But I am yet to validate multiple scenarios. Closing for now, will reopen if I find it broken again later. |
I have following models:
foo.yang
bar.yang
When I create an instance of foo (under yang-express using published URLs), and then try to create a bar instance supplying correct value of bar leafref, I always see error regarding unable to resolve the leafref.
The text was updated successfully, but these errors were encountered: