Hi Hang, You have to use named arguments. Change in 17.01.
Best regards, Ole > On 18 Feb 2017, at 19:13, Hang Shi <hangshi...@gmail.com> wrote: > > Hi, > > I am trying to use VPP python APIs and seeing the tracebacks (see below) for > Python APIs with parameters, while Python APIs without parameters are fine. > Will anyone help? The APIs I tried is vpp.sw_interface_add_del_address. > > below is the traceback and code snippets. Whole codes are attached as well. > > > <snip> > Traceback (most recent call last): > File "set_addr_test.py", line 53, in <module> > main() > File "set_addr_test.py", line 45, in main > loop = vpp.sw_interface_add_del_address(ifindex, 1, 1, 0, 16, addr) > TypeError: <lambda>() takes exactly 0 arguments (6 given) > Cleaning up VPP on exit > <snip> > > > <snip> > .... > loop = vpp.create_loopback() > print(loop) > ifindex = loop.sw_if_index > print('{}'.format(ifindex)) > > addr = str(IPv6Address(u'1::1').packed) > loop = vpp.sw_interface_add_del_address(ifindex, 1, 1, 0, 16, addr) > ... > <snip> > > > The syntax from help for this API: > > sw_interface_add_del_address(**kwargs) > u16 _vl_msg_id, u32 client_index, u32 context, u32 sw_if_index, u8 > is_add, u8 is_ipv6, u8 del_all, u8 address_length, u8 address > > > > regards, > Hang > > > > > > > > > > > <set_addr_test.py> > _______________________________________________ > vpp-dev mailing list > vpp-dev@lists.fd.io > https://lists.fd.io/mailman/listinfo/vpp-dev _______________________________________________ vpp-dev mailing list vpp-dev@lists.fd.io https://lists.fd.io/mailman/listinfo/vpp-dev