Skip to content

Commit c572b00

Browse files
committed
network: Do not show evpn_vni if not returned by API
The Router object in the SDK defines the evpn_vni in the Depends-On patch. The attribute is returned in the body only if the EVPN extension is enabled in Neutron but the Router object in SDK attempts to show it always. This patch makes the column visible only if it's really present in the API response. Assisted-By: Claude Opus 4.6 Related-Bug: #2144617 Change-Id: I8747f3cb753a115e7955b0a0ea136431fdade0dd Signed-off-by: Jakub Libosvar <libosvar@redhat.com>
1 parent 32cd99b commit c572b00

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

openstackclient/network/v2/router.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@ def _get_columns(
8888
if item.is_distributed is None:
8989
hidden_columns.append('is_distributed')
9090
column_map.pop('is_distributed')
91+
if not hasattr(item, 'evpn_vni'):
92+
hidden_columns.append('evpn_vni')
9193
return utils.get_osc_show_columns_for_sdk_resource(
9294
item, column_map, hidden_columns
9395
)

0 commit comments

Comments
 (0)