using ydk
jedelman8 opened this issue · comments
UPDATE: I had to install core, then ietf, to allow me to install the oc models. README should be updated.
Keep the original issue for others to see:
Can someone tell me how to get over this hump of a conversioning issue?
ERROR:
Could not find a version that satisfies the requirement ydk>=0.5.0 (from ydk-models-openconfig==0.1.0) (from versions: )
No matching distribution found for ydk>=0.5.0 (from ydk-models-openconfig==0.1.0)
(ydkpy) jason@ubuntu:openconfig (master)$
FULL WORFKLOW
(ydkpy) jason@ubuntu:tools$ git clone https://github.com/CiscoDevNet/ydk-py
Cloning into 'ydk-py'...
remote: Counting objects: 3811, done.
remote: Total 3811 (delta 0), reused 0 (delta 0), pack-reused 3811
Receiving objects: 100% (3811/3811), 61.15 MiB | 904.00 KiB/s, done.
Resolving deltas: 100% (2520/2520), done.
Checking connectivity... done.
Checking out files: 100% (541/541), done.
(ydkpy) jason@ubuntu:tools$ cd ydk-py/
(ydkpy) jason@ubuntu:ydk-py (master)$
(ydkpy) jason@ubuntu:ydk-py (master)$
(ydkpy) jason@ubuntu:ydk-py (master)$ cd openconfig/
(ydkpy) jason@ubuntu:openconfig (master)$ python setup.py sdist
running sdist
running egg_info
creating ydk_models_openconfig.egg-info
writing requirements to ydk_models_openconfig.egg-info/requires.txt
writing ydk_models_openconfig.egg-info/PKG-INFO
writing namespace_packages to ydk_models_openconfig.egg-info/namespace_packages.txt
writing top-level names to ydk_models_openconfig.egg-info/top_level.txt
writing dependency_links to ydk_models_openconfig.egg-info/dependency_links.txt
writing manifest file 'ydk_models_openconfig.egg-info/SOURCES.txt'
reading manifest file 'ydk_models_openconfig.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'ydk_models_openconfig.egg-info/SOURCES.txt'
warning: sdist: standard file not found: should have one of README, README.rst, README.txt
running check
creating ydk-models-openconfig-0.1.0
creating ydk-models-openconfig-0.1.0/ydk
creating ydk-models-openconfig-0.1.0/ydk/models
creating ydk-models-openconfig-0.1.0/ydk/models/_deviate
creating ydk-models-openconfig-0.1.0/ydk/models/openconfig
creating ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
creating ydk-models-openconfig-0.1.0/ydk_models_openconfig.egg-info
copying files to ydk-models-openconfig-0.1.0...
copying MANIFEST.in -> ydk-models-openconfig-0.1.0
copying README.md -> ydk-models-openconfig-0.1.0
copying setup.py -> ydk-models-openconfig-0.1.0
copying ydk/__init__.py -> ydk-models-openconfig-0.1.0/ydk
copying ydk/models/__init__.py -> ydk-models-openconfig-0.1.0/ydk/models
copying ydk/models/_deviate/__init__.py -> ydk-models-openconfig-0.1.0/ydk/models/_deviate
copying ydk/models/openconfig/__init__.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/_yang_ns.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/bgp.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/bgp_policy.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/bgp_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_if_aggregate.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_if_ethernet.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_if_ip.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_interfaces.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_inventory.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_inventory_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_mpls.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_mpls_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_rpc_api.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_telemetry.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_terminal_device.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_transport_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/openconfig_vlan.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/policy_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/routing_policy.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig
copying ydk/models/openconfig/_meta/__init__.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_bgp.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_bgp_policy.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_bgp_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_if_aggregate.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_if_ethernet.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_if_ip.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_interfaces.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_inventory.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_inventory_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_mpls.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_mpls_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_rpc_api.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_telemetry.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_terminal_device.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_transport_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_openconfig_vlan.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_policy_types.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk/models/openconfig/_meta/_routing_policy.py -> ydk-models-openconfig-0.1.0/ydk/models/openconfig/_meta
copying ydk_models_openconfig.egg-info/PKG-INFO -> ydk-models-openconfig-0.1.0/ydk_models_openconfig.egg-info
copying ydk_models_openconfig.egg-info/SOURCES.txt -> ydk-models-openconfig-0.1.0/ydk_models_openconfig.egg-info
copying ydk_models_openconfig.egg-info/dependency_links.txt -> ydk-models-openconfig-0.1.0/ydk_models_openconfig.egg-info
copying ydk_models_openconfig.egg-info/namespace_packages.txt -> ydk-models-openconfig-0.1.0/ydk_models_openconfig.egg-info
copying ydk_models_openconfig.egg-info/requires.txt -> ydk-models-openconfig-0.1.0/ydk_models_openconfig.egg-info
copying ydk_models_openconfig.egg-info/top_level.txt -> ydk-models-openconfig-0.1.0/ydk_models_openconfig.egg-info
Writing ydk-models-openconfig-0.1.0/setup.cfg
creating dist
Creating tar archive
removing 'ydk-models-openconfig-0.1.0' (and everything under it)
(ydkpy) jason@ubuntu:openconfig (master)$ pip install dist/ydk-*.tar.gz
Processing ./dist/ydk-models-openconfig-0.1.0.tar.gz
Requirement already satisfied (use --upgrade to upgrade): ydk-models-openconfig==0.1.0 from file:///home/jason/tools/ydk-py/openconfig/dist/ydk-models-openconfig-0.1.0.tar.gz in /home/jason/.virtualenvs/ydkpy/lib/python2.7/site-packages/ydk_models_openconfig-0.1.0-py2.7.egg
Collecting ecdsa==0.13 (from ydk-models-openconfig==0.1.0)
Using cached ecdsa-0.13-py2.py3-none-any.whl
Collecting enum34==1.1.3 (from ydk-models-openconfig==0.1.0)
Using cached enum34-1.1.3-py2.py3-none-any.whl
Collecting lxml==3.4.4 (from ydk-models-openconfig==0.1.0)
Using cached lxml-3.4.4.tar.gz
Collecting paramiko==1.15.2 (from ydk-models-openconfig==0.1.0)
Using cached paramiko-1.15.2-py2.py3-none-any.whl
Collecting pyang==1.6 (from ydk-models-openconfig==0.1.0)
Using cached pyang-1.6-py2.py3-none-any.whl
Collecting pycrypto==2.6.1 (from ydk-models-openconfig==0.1.0)
Collecting Twisted>=16.0.0 (from ydk-models-openconfig==0.1.0)
Using cached Twisted-16.3.2.tar.bz2
Collecting protobuf==3.0.0b2.post2 (from ydk-models-openconfig==0.1.0)
Using cached protobuf-3.0.0b2.post2-py2-none-any.whl
Collecting ncclient>=0.4.7 (from ydk-models-openconfig==0.1.0)
Using cached ncclient-0.5.2.tar.gz
Collecting ydk>=0.5.0 (from ydk-models-openconfig==0.1.0)
Could not find a version that satisfies the requirement ydk>=0.5.0 (from ydk-models-openconfig==0.1.0) (from versions: )
No matching distribution found for ydk>=0.5.0 (from ydk-models-openconfig==0.1.0)
(ydkpy) jason@ubuntu:openconfig (master)$
Please install . To do this, cd ydk-py/core; python setup.py sdist; pip install dist/*
Sorry if this is not clear from the README. Maybe the README needs an update
Both core and IETF bundle need to be installed first. We're in the process of adding more details to the README. This workflow works for me:
saalvare@ohlone:CiscoDevNet$ mkvirtualenv ydk-0.5.0
(ydk-0.5.0) saalvare@ohlone:CiscoDevNet$ git clone git@github.com:CiscoDevNet/ydk-py.git
(ydk-0.5.0) saalvare@ohlone:CiscoDevNet$ cd ydk-py/core/
(ydk-0.5.0) saalvare@ohlone:core (master=)$ python setup.py sdist
(ydk-0.5.0) saalvare@ohlone:core (master=)$ pip install dist/ydk-0.5.0.tar.gz
(ydk-0.5.0) saalvare@ohlone:core (master=)$ cd ../ietf
(ydk-0.5.0) saalvare@ohlone:ietf (master=)$ python setup.py sdist
(ydk-0.5.0) saalvare@ohlone:ietf (master=)$ pip install dist/ydk-models-ietf-0.1.0.tar.gz
(ydk-0.5.0) saalvare@ohlone:ietf (master=)$ cd ../openconfig/
(ydk-0.5.0) saalvare@ohlone:openconfig (master=)$ pip install dist/ydk-models-openconfig-0.1.0.tar.gz
(ydk-0.5.0) saalvare@ohlone:openconfig (master=)$
(ydk-0.5.0) saalvare@ohlone:openconfig (master=)$ pip list | grep ydk
ydk (0.5.0)
ydk-models-ietf (0.1.0)
ydk-models-openconfig (0.1.0)
(ydk-0.5.0) saalvare@ohlone:openconfig (master=)$
(ydk-0.5.0) saalvare@ohlone:openconfig (master=)$ python
Python 2.7.6 (default, Jun 22 2015, 17:58:13)
[GCC 4.8.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import ydk.models.openconfig
>>>
(ydk-0.5.0) saalvare@ohlone:openconfig (master=)$
Thanks yep I got it. README could be improved...I can do it time permitting!