CiscoDevNet / yang-explorer

An open-source Yang Browser and RPC Builder Application
Apache License 2.0
437 stars 177 forks source link

Can't upload Yang models #105

Closed Thom9790 closed 4 years ago

Thom9790 commented 4 years ago

Hello there!

After a long week of trials and tribulations, I have finally gotten Yang Explorer to (more or less) work on a Ubuntu 18.04.02 virtual machine. However I cannot upload any models (other than the default-models, which can be uploaded fine) without getting either one or several errors. I get either:

I downloaded the models and placed the folders in the same folder as Yang Explorer called "models".

I've had trouble, since there isn't a single even remotely useful guide on how to set this up. This isn't helped with me being a beginner at Linux. Is there anyone who has a constructive answer to what I have done wrong?

Attached is a screenshot of the error I get when trying to upload a module.

YangBlows

Thom9790 commented 4 years ago

Nevermind, I fixed it. The pyang in the Yang Explorer folder was 1.6, when it needed to be newer.

manas42 commented 4 years ago

@Thom9790 Can you share how you did it to update the pyang in Yang Explorer? I have installed pyang 2.1 on my server (pip install pyang), but I'm still having the same problems as you did.

Thom9790 commented 4 years ago

@manas42 Sure. First I removed the pyang folder in the yang-explorer/v/bin/ folder

Then I went back to the yang base-folder and did a targeted installation to the v/bin/ folder. I wrote the commands I used below:

cd yang-explorer/ pip install pyang --target v/bin/

This should installed the newest version of Pyang into the yang-explorer folder. Hope this helped you.

manas42 commented 4 years ago

@Thom9790 Thanks a lot!