Error generating bindings for ietf-yang-library
I get the following error when I try to generate bindings for this model: http://www.netconfcentral.org/modules/ietf-yang-library
pyang --plugindir $PYBINDPLUGIN -f pybind -o binding.py ietf-yang-library.yang Traceback (most recent call last):
File "/usr/local/bin/pyang", line 434, in
@mathieu-mercier I realize this is quite an old issue, but I believe this has been fixed with the recent work on the library.
I've just performed a test using the latest copy of the ietf-yang-library.yang, and was able to successfully generate bindings.
Note that I was not able to use the ietf-datastores.yang from netconfcentral.org, as it is outdated and has an invalid bare base statement on line 63. Instead, I had to use the latest version of the file copied directly from RFC 8342.
Confirming that this is now working:
$pyang --plugindir $PYBINDPLUGIN -f pybind -o binding.py ietf-yang-library.yang
$ echo $?
0
$ file binding.py
binding.py: Python script, ASCII text executable, with very long lines
I'm still seeing this issue in the latest version. I'm unable to generate bindings for ietf-yang-library.yang or ietf-interfaces.yang I'm running the following version; pyang==2.0.1 pyangbind==0.8.1
@gametack could you please indicate where are you getting the models from? A comment below stated that the latest models from https://tools.ietf.org/html/rfc8342#section-7
With the exact source of the models and versions you provided, we can attempt to reproduce. But already 2 comments indicate this actually works...
Closing issues without recent activity