08-30-2020 07:13 PM
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
##############################################################################
Solved! Go to Solution.
08-31-2020 10:38 AM
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.
08-31-2020 10:38 AM
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.
08-31-2020 08:49 PM
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
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: