Comments (8)
After some retries, I was able to use pyangbind 0.8.3 from source, and it worked ok. The error presented itself only when using the PyPi package.
I created a Package 0.8.3.post1 with a fresh build from source. @gunhanoral , could you please try again?
from pyangbind.
Probably unrelated but when I tried to import from the file generated with docker-v0.8.2 using pyangbind v0.8.3 installed on my computer I got ModuleNotFoundError: No module named 'pyangbind.lib'
error. After I downgrade to v0.8.2 I was able to import the same file without a problem.
from pyangbind.
Hello @gunhanoral , we are aware of some breakage and had yanked v0.8.3. @JoseIgnacioTamayo I noticed v0.8.3 was unyanked on PyPi, is the error here related to the original problem?
from pyangbind.
Interesting.
I updated the release notes of v0.8.3. Indeed, files generated with 0.8.2 depend on bitarray
while files generated with 0.8.3 depend on pyangbind...YANGBinary
. So indeed 0.8.3 is not backwards compatible.
I un-yanked the release because I was able to use and generate files. I did not had the error reported in here. I will try to reproduce it and maybe fix it.
The fact that 0.8.3 is not backwards-compatible, grants it to be yanked again until fixed? Maybe...
from pyangbind.
Yep, using oc_config_validate, I get the same error as reported. I yanked 0.8.3 again until:
- This error is fixed
- The release is backwards compatible (might be as simple as a importing
bitarray
library)
from pyangbind.
For the second problem:
I tried to import from the file generated with docker-v0.8.2 using pyangbind v0.8.3 installed on my computer I got
ModuleNotFoundError: No module named 'pyangbind.lib' error
The bindings are not self-contained, they import some classes from pyangbind. In order to properly support the YANG bytes
type, I've added a new class to map the type, and bindings now reference that new class; that's why the older pyangbind version can't be used with bindings generated by the new version.
I'd be very careful before promising that bindings generated by pyangbind version X can be used on a machine running pyangbind version Y. It'll mean you can't add or remove functions or classes referenced from bindings, or rename them, move to a different module, accept extra or fewer arguments, change their behaviour, etc.
To be perfectly honest, I hadn't thought about that sort of compatibility. I always used pyangbind to generate bindings at application startup time.
from pyangbind.
Build completes successfully. Thanks!
Also there's no problem with importing from the generated file.
from pyangbind.
Great! So the issue was just the package 0.8.3 in PyPi. Something went wrong when I built and uploaded it. The latest package 0.8.3.post1 works as intended.
from pyangbind.
Related Issues (20)
- pyangbind is not taking care of "when" statement in yang definitions. HOT 2
- Problem with list's key made of multiple leaf identifiers HOT 3
- Is pyangbind still maintained? HOT 3
- RuntimeError when importing an older revision of a YANG file HOT 1
- Failure on OpenConfig BFD Model HOT 3
- Fix binary type representation HOT 2
- Integration and Sample UnitTests using BGP are broken
- __add_metadata is not adding the @metadata object to JSON or XML HOT 2
- Support `bits` type HOT 1
- pyangbind fails processing typedef union with default value
- pyangbind-0.8.4 installation failed HOT 2
- Can not be directly used in ncclient? HOT 2
- TypeError: unhandled keyword with children case HOT 3
- How to filter by leaf? HOT 3
- Process for moving a list element HOT 2
- When we generate python code from Yang module, missing attributes in class HOT 6
- Presence container support HOT 15
- Primary key of a list cannot be of type string with a specific pattern HOT 6
- Multiple base for identity not working in restriction_arg
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyangbind.