cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1339
Views
0
Helpful
1
Replies

acitoolkit, port channel binding to EPG issue

jhongrack-choi
Level 1
Level 1

I'm trying bind port channel to EPG using below script but got an error 'IndexError: list index out of range'

!

pc = aci.PortChannel('ipgl-test-pg1-pc')      ##ipgl-test-pg1-pc is already created on fabric
!
vlan_intf = aci.L2Interface('vlan-304','vlan','304')
vlan_intf.attach(pc)
!acitoolkit, APIC
tenant = aci.Tenant('test111')
app = aci.AppProfile("ap111", tenant)
epg = aci.EPG("epg111", app)
epg.attach(vlan_intf)
!
resp = tenant.push_to_apic(session)

 

##output when run the script

C:\Tools\01_API>python 05_epg_associate_vpc.py
Traceback (most recent call last):
File "05_epg_associate_vpc.py", line 29, in <module>
resp = tenant.push_to_apic(session)
File "C:\Users\pcceadmin\AppData\Local\Programs\Python\Python37-32\lib\site-pa
ckages\acitoolkit-0.4-py3.7.egg\acitoolkit\acitoolkit.py", line 113, in push_to_
apic
File "C:\Users\pcceadmin\AppData\Local\Programs\Python\Python37-32\lib\site-pa
ckages\acitoolkit-0.4-py3.7.egg\acitoolkit\acitoolkit.py", line 102, in get_json

File "C:\Users\pcceadmin\AppData\Local\Programs\Python\Python37-32\lib\site-pa
ckages\acitoolkit-0.4-py3.7.egg\acitoolkit\acibaseobject.py", line 1027, in get_
json
File "C:\Users\pcceadmin\AppData\Local\Programs\Python\Python37-32\lib\site-pa
ckages\acitoolkit-0.4-py3.7.egg\acitoolkit\acitoolkit.py", line 341, in get_json

File "C:\Users\pcceadmin\AppData\Local\Programs\Python\Python37-32\lib\site-pa
ckages\acitoolkit-0.4-py3.7.egg\acitoolkit\acibaseobject.py", line 1027, in get_
json
File "C:\Users\pcceadmin\AppData\Local\Programs\Python\Python37-32\lib\site-pa
ckages\acitoolkit-0.4-py3.7.egg\acitoolkit\acitoolkit.py", line 1392, in get_jso
n
File "C:\Users\pcceadmin\AppData\Local\Programs\Python\Python37-32\lib\site-pa
ckages\acitoolkit-0.4-py3.7.egg\acitoolkit\acitoolkit.py", line 441, in _get_pat
h
File "C:\Users\pcceadmin\AppData\Local\Programs\Python\Python37-32\lib\site-pa
ckages\acitoolkit-0.4-py3.7.egg\acitoolkit\acitoolkit.py", line 5025, in _get_pa
th
IndexError: list index out of range

 

Advise please

1 Reply 1

r.nalesso
Level 1
Level 1

Hi, did you find out how to fix the issue? I'm currently working with acitoolkit and trying to automate the EPG propagation into vPCs