01-18-2024 10:19 AM
from pyats.topology import loader
testbed = loader.load('pyATS/testbed.yaml')
dev = testbed.devices['cat8000v']
dev.connect(via='ssh')
dev.api.unconfigure_trustpoint(tp_name = 'TP-NAME')
I get a Traceback with the final error... Could not find the API under ('iosxe', 'router', None), and common
when i do a dir(dev.api) I get a subset of the api functions I would expect to get according to:
https://pubhub.devnetcloud.com/media/genie-feature-browser/docs/#/apis
I've had this working in the past, but I don't know what's different. My venv? My testbed.yaml file? my import statement? Anyone?
Solved! Go to Solution.
01-18-2024 03:38 PM
Thanks bigevilbeard for your response. It did guide me in the right direction and I did figure it out. testbed.yaml file had ios_xe as the os instead of iosxe... so only the common methods were added to the object. I fixed the typo and all the iosxe methods I expected were there.
01-18-2024 10:38 AM
Check pyATS Version and Packages see what hey are update pyATS to the latest version using pip install --upgrade pyats
v
erify that you have the necessary Genie packages installed for your device type
01-18-2024 03:23 PM
pyats is up to date. I'm not sure how to determine whether I have appropriate genie packages. I added a Cat8000v to my environment when I was using a Cat9000 before, so this could be my issue. I need Genie packages for the 8000v maybe?
01-18-2024 03:38 PM
Thanks bigevilbeard for your response. It did guide me in the right direction and I did figure it out. testbed.yaml file had ios_xe as the os instead of iosxe... so only the common methods were added to the object. I fixed the typo and all the iosxe methods I expected were there.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide