cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
157
Views
0
Helpful
2
Replies
Highlighted

Yang Develop Kit----hasn't found Cisco_IOS_XE_native from ydk.models.cisco_ios_xe---2nd around

Hi Yan,

 

Thank you for your support and have a nice Monday.

 

I am sorry that I was not able to reply to you in previous mail as system told there were some issues in the mail.

 

Now I have to initiate a new one.

 

Please see output from linux terminal.

It looks like my packet install in the different directory "/dist-packages/" while yours is in "/site-packages/"

 

/usr/local/lib/python2.7/dist-packages/ydk/models/cisco_ios_xe/Cisco_IOS_XE_native.py

 

 

root@YDK64:~# find / -name Cisco_IOS_XE_native.py
/root/libssh-0.7.6/build/ydk-py/cisco-ios-xe/ydk/models/cisco_ios_xe/Cisco_IOS_XE_native.py
/home/jzhang/Downloads/ydk-models-cisco-ios-xe-16.9.3.post1/ydk/models/cisco_ios_xe/Cisco_IOS_XE_native.py
/usr/local/lib/python2.7/dist-packages/ydk/models/cisco_ios_xe/Cisco_IOS_XE_native.py
find: ‘/run/user/1000/gvfs’: Permission denied
root@YDK64:~#

 

 

##############################################################################

Hi Jacky

Please check package installation. For example, in my python3 virtual environment:

$ ls ../venv/lib/python3.7/site-packages/ydk/models/cisco_ios_xe/Cisco_IOS_XE_native.py
If this file is not found, then something wrong with package installation.

If found, then you need reindex your IDE.

Yan Gorelik
YDK Solutions
View solution in original post

##############################################################################

Jacky Zhang
Global Telecom
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Participant

Hi Jacky

I can see that you are running YDK with Python 2.7. This version has been deprecated since January 1 of this year. Therefore I strongly advise you to switch to Python 3 software. In addition, the user is always encouraged to have virtual Python environment in order to separate system installation from the application environment.

Also. I am not sure what platform do you use for your development. If it is Centos-7 or RHEL-7, then bundle installation for Python2 is slightly different.

Yan Gorelik
YDK Solutions

View solution in original post

2 REPLIES 2
Highlighted
Participant

Hi Jacky

I can see that you are running YDK with Python 2.7. This version has been deprecated since January 1 of this year. Therefore I strongly advise you to switch to Python 3 software. In addition, the user is always encouraged to have virtual Python environment in order to separate system installation from the application environment.

Also. I am not sure what platform do you use for your development. If it is Centos-7 or RHEL-7, then bundle installation for Python2 is slightly different.

Yan Gorelik
YDK Solutions

View solution in original post

Highlighted

Hi Yan,

 

Thanks a lot.

I will try to use Python virtual environment for my next DevNet development.  After I move develop platform to virtual environment. I will check the package installation path again. Thanks.

 

For another question regarding how to check YDK and IOS-XE/XR version.  
Thank you very much for your nice professional explanation in another mail.


Today,  I read the document (https://github.com/CiscoDevNet/ydk-gen#generate-ydk-components).  I found it also answer this question from different point of view.

*********************************************************************************************************

Some model bundles have bin packaged and published in Pypi repository. These bundles can be installed with pip utility. For example, when executing pip install ydk-models-cisco-ios-xr, you will install the latest released in PyPi IOS XR device package

**********************************************************************************************************

So in PYPI,    IOS-XE is 16.9.3.   IOS-XR is 6.6.3,   NX-OS iws 9.3.1

Jacky Zhang
Global Telecom
Content for Community-Ad
Cisco Community October 2020 Spotlight Award Winners