From 4487abdfcb46f28fc2859f5b5446b885b12ee612 Mon Sep 17 00:00:00 2001 From: arlakshm <55814491+arlakshm@users.noreply.github.com> Date: Mon, 17 Aug 2020 17:22:30 -0700 Subject: [PATCH] Fix to prevent classification all portchannels is External (#5202) Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan Fix the checks in the API is_port_channel_internal --- src/sonic-py-common/sonic_py_common/multi_asic.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sonic-py-common/sonic_py_common/multi_asic.py b/src/sonic-py-common/sonic_py_common/multi_asic.py index 966b5d238e..8fc22141e7 100644 --- a/src/sonic-py-common/sonic_py_common/multi_asic.py +++ b/src/sonic-py-common/sonic_py_common/multi_asic.py @@ -265,7 +265,7 @@ def is_port_channel_internal(port_channel, namespace=None): port_channels = config_db.get_table(PORT_CHANNEL_CFG_DB_TABLE) if port_channel in port_channels: - if 'members' in port_channel: + if 'members' in port_channels[port_channel]: members = port_channels[port_channel]['members'] if is_port_internal(members[0], namespace): return True