diff mbox series

[ovs-dev] python: allow UnixctlClient to get argv as tuple in transact

Message ID 20200316032947.2252-1-moshele@mellanox.com
State New
Headers show
Series [ovs-dev] python: allow UnixctlClient to get argv as tuple in transact | expand

Commit Message

Moshe Levi March 16, 2020, 3:29 a.m. UTC
Currently transact check that argv is of type list. This patch
allow argv also to be tuple.

Signed-off-by: Moshe Levi <moshele@mellanox.com>
---
 python/ovs/unixctl/client.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/python/ovs/unixctl/client.py b/python/ovs/unixctl/client.py
index 8283f99bb..50f619f4b 100644
--- a/python/ovs/unixctl/client.py
+++ b/python/ovs/unixctl/client.py
@@ -28,7 +28,7 @@  class UnixctlClient(object):
 
     def transact(self, command, argv):
         assert isinstance(command, str)
-        assert isinstance(argv, list)
+        assert isinstance(argv, (list, tuple))
         for arg in argv:
             assert isinstance(arg, str)