From 6ee7b8d138e07bfc37c5cd887f7afa49cdabb02f Mon Sep 17 00:00:00 2001 From: Dean Troyer Date: Fri, 30 Aug 2019 12:53:15 -0500 Subject: [PATCH] Format location columns in network commands These return a Munch from the SDK, which can be handled exactly like a dict so do that. Note that the location column has a nested project dict in the return value, this is addressed separately in osc_lib.format_columns in https://review.opendev.org/#/c/679474/. Change-Id: I99a6d192749a4ac76777f72be8118261c0521cb0 Signed-off-by: Dean Troyer --- openstackclient/network/v2/address_scope.py | 10 ++++++++-- openstackclient/network/v2/floating_ip.py | 2 ++ openstackclient/network/v2/ip_availability.py | 2 ++ openstackclient/network/v2/network.py | 1 + openstackclient/network/v2/network_agent.py | 1 + .../v2/network_auto_allocated_topology.py | 17 ++++++++++++----- openstackclient/network/v2/network_flavor.py | 10 ++++++++-- .../network/v2/network_flavor_profile.py | 10 ++++++++-- openstackclient/network/v2/network_meter.py | 10 ++++++++-- .../network/v2/network_meter_rule.py | 10 ++++++++-- .../network/v2/network_qos_policy.py | 10 ++++++++-- openstackclient/network/v2/network_qos_rule.py | 10 ++++++++-- .../network/v2/network_qos_rule_type.py | 8 +++++++- openstackclient/network/v2/network_rbac.py | 10 ++++++++-- openstackclient/network/v2/network_segment.py | 10 ++++++++-- .../network/v2/network_segment_range.py | 9 +++++++-- openstackclient/network/v2/port.py | 1 + openstackclient/network/v2/router.py | 1 + openstackclient/network/v2/security_group.py | 3 +++ .../network/v2/security_group_rule.py | 10 ++++++++-- openstackclient/network/v2/subnet.py | 1 + openstackclient/network/v2/subnet_pool.py | 1 + 22 files changed, 119 insertions(+), 28 deletions(-) diff --git a/openstackclient/network/v2/address_scope.py b/openstackclient/network/v2/address_scope.py index 71c1a9afb7..7efbb6311e 100644 --- a/openstackclient/network/v2/address_scope.py +++ b/openstackclient/network/v2/address_scope.py @@ -15,6 +15,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -27,6 +28,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'is_shared': 'shared', @@ -100,7 +106,7 @@ class CreateAddressScope(command.ShowOne): attrs = _get_attrs(self.app.client_manager, parsed_args) obj = client.create_address_scope(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns, formatters={}) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) @@ -289,6 +295,6 @@ class ShowAddressScope(command.ShowOne): parsed_args.address_scope, ignore_missing=False) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns, formatters={}) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) diff --git a/openstackclient/network/v2/floating_ip.py b/openstackclient/network/v2/floating_ip.py index 8ac8e10703..e0aa0435ed 100644 --- a/openstackclient/network/v2/floating_ip.py +++ b/openstackclient/network/v2/floating_ip.py @@ -13,6 +13,7 @@ """IP Floating action implementations""" +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import utils @@ -24,6 +25,7 @@ from openstackclient.network.v2 import _tag _formatters = { + 'location': format_columns.DictColumn, 'port_details': utils.format_dict, } diff --git a/openstackclient/network/v2/ip_availability.py b/openstackclient/network/v2/ip_availability.py index ddc88e557e..c026baa0cc 100644 --- a/openstackclient/network/v2/ip_availability.py +++ b/openstackclient/network/v2/ip_availability.py @@ -21,7 +21,9 @@ from openstackclient.i18n import _ from openstackclient.identity import common as identity_common from openstackclient.network import sdk_utils + _formatters = { + 'location': format_columns.DictColumn, 'subnet_ip_availability': format_columns.ListDictColumn, } diff --git a/openstackclient/network/v2/network.py b/openstackclient/network/v2/network.py index 63aec71497..09f3556c43 100644 --- a/openstackclient/network/v2/network.py +++ b/openstackclient/network/v2/network.py @@ -40,6 +40,7 @@ _formatters = { 'subnet_ids': format_columns.ListColumn, 'admin_state_up': AdminStateColumn, 'is_admin_state_up': AdminStateColumn, + 'location': format_columns.DictColumn, 'router:external': RouterExternalColumn, 'is_router_external': RouterExternalColumn, 'availability_zones': format_columns.ListColumn, diff --git a/openstackclient/network/v2/network_agent.py b/openstackclient/network/v2/network_agent.py index 1678485434..a6ed36299c 100644 --- a/openstackclient/network/v2/network_agent.py +++ b/openstackclient/network/v2/network_agent.py @@ -43,6 +43,7 @@ _formatters = { 'alive': AliveColumn, 'admin_state_up': AdminStateColumn, 'is_admin_state_up': AdminStateColumn, + 'location': format_columns.DictColumn, 'configurations': format_columns.DictColumn, } diff --git a/openstackclient/network/v2/network_auto_allocated_topology.py b/openstackclient/network/v2/network_auto_allocated_topology.py index 36f392006e..f6070a0277 100644 --- a/openstackclient/network/v2/network_auto_allocated_topology.py +++ b/openstackclient/network/v2/network_auto_allocated_topology.py @@ -15,6 +15,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import utils @@ -25,6 +26,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'tenant_id': 'project_id', @@ -93,16 +99,17 @@ class CreateAutoAllocatedTopology(command.ShowOne): obj = client.validate_auto_allocated_topology(parsed_args.project) columns = _format_check_resource_columns() - data = utils.get_item_properties(_format_check_resource(obj), - columns, - formatters={}) - + data = utils.get_item_properties( + _format_check_resource(obj), + columns, + formatters=_formatters, + ) return (columns, data) def get_topology(self, client, parsed_args): obj = client.get_auto_allocated_topology(parsed_args.project) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns, formatters={}) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) def take_action(self, parsed_args): diff --git a/openstackclient/network/v2/network_flavor.py b/openstackclient/network/v2/network_flavor.py index c9d368bfc1..355d04c1af 100644 --- a/openstackclient/network/v2/network_flavor.py +++ b/openstackclient/network/v2/network_flavor.py @@ -15,6 +15,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -27,6 +28,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'is_enabled': 'enabled', @@ -136,7 +142,7 @@ class CreateNetworkFlavor(command.ShowOne): attrs = _get_attrs(self.app.client_manager, parsed_args) obj = client.create_flavor(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns, formatters={}) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) @@ -300,5 +306,5 @@ class ShowNetworkFlavor(command.ShowOne): client = self.app.client_manager.network obj = client.find_flavor(parsed_args.flavor, ignore_missing=False) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return display_columns, data diff --git a/openstackclient/network/v2/network_flavor_profile.py b/openstackclient/network/v2/network_flavor_profile.py index 6cf0c4124d..492fd432a9 100644 --- a/openstackclient/network/v2/network_flavor_profile.py +++ b/openstackclient/network/v2/network_flavor_profile.py @@ -13,6 +13,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -25,6 +26,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'is_enabled': 'enabled', @@ -110,7 +116,7 @@ class CreateNetworkFlavorProfile(command.ShowOne): obj = client.create_service_profile(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns, formatters={}) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) @@ -246,5 +252,5 @@ class ShowNetworkFlavorProfile(command.ShowOne): obj = client.find_service_profile(parsed_args.flavor_profile, ignore_missing=False) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) diff --git a/openstackclient/network/v2/network_meter.py b/openstackclient/network/v2/network_meter.py index df0e1da119..cde7a30403 100644 --- a/openstackclient/network/v2/network_meter.py +++ b/openstackclient/network/v2/network_meter.py @@ -15,6 +15,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -26,6 +27,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'is_shared': 'shared', @@ -102,7 +108,7 @@ class CreateMeter(command.ShowOne): attrs = _get_attrs(self.app.client_manager, parsed_args) obj = client.create_metering_label(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns, formatters={}) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) @@ -186,5 +192,5 @@ class ShowMeter(command.ShowOne): obj = client.find_metering_label(parsed_args.meter, ignore_missing=False) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return display_columns, data diff --git a/openstackclient/network/v2/network_meter_rule.py b/openstackclient/network/v2/network_meter_rule.py index 49ff9e1b0e..5f31255a69 100644 --- a/openstackclient/network/v2/network_meter_rule.py +++ b/openstackclient/network/v2/network_meter_rule.py @@ -15,6 +15,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -26,6 +27,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'tenant_id': 'project_id', @@ -116,7 +122,7 @@ class CreateMeterRule(command.ShowOne): attrs = _get_attrs(self.app.client_manager, parsed_args) obj = client.create_metering_label_rule(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns, formatters={}) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) @@ -199,5 +205,5 @@ class ShowMeterRule(command.ShowOne): obj = client.find_metering_label_rule(parsed_args.meter_rule_id, ignore_missing=False) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return display_columns, data diff --git a/openstackclient/network/v2/network_qos_policy.py b/openstackclient/network/v2/network_qos_policy.py index fd5ff93771..1622de4a7a 100644 --- a/openstackclient/network/v2/network_qos_policy.py +++ b/openstackclient/network/v2/network_qos_policy.py @@ -15,6 +15,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -27,6 +28,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'is_shared': 'shared', @@ -119,7 +125,7 @@ class CreateNetworkQosPolicy(command.ShowOne): attrs = _get_attrs(self.app.client_manager, parsed_args) obj = client.create_qos_policy(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns, formatters={}) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) @@ -279,5 +285,5 @@ class ShowNetworkQosPolicy(command.ShowOne): obj = client.find_qos_policy(parsed_args.policy, ignore_missing=False) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) diff --git a/openstackclient/network/v2/network_qos_rule.py b/openstackclient/network/v2/network_qos_rule.py index 28c5600aa6..d74beda70f 100644 --- a/openstackclient/network/v2/network_qos_rule.py +++ b/openstackclient/network/v2/network_qos_rule.py @@ -15,6 +15,7 @@ import itertools +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -46,6 +47,11 @@ ACTION_SET = 'update' ACTION_SHOW = 'get' +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'tenant_id': 'project_id', @@ -208,7 +214,7 @@ class CreateNetworkQosRule(command.ShowOne): msg = (_('Failed to create Network QoS rule: %(e)s') % {'e': e}) raise exceptions.CommandError(msg) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return display_columns, data @@ -358,5 +364,5 @@ class ShowNetworkQosRule(command.ShowOne): {'rule': rule_id, 'e': e}) raise exceptions.CommandError(msg) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return display_columns, data diff --git a/openstackclient/network/v2/network_qos_rule_type.py b/openstackclient/network/v2/network_qos_rule_type.py index 7b92c8ad4b..e842944cce 100644 --- a/openstackclient/network/v2/network_qos_rule_type.py +++ b/openstackclient/network/v2/network_qos_rule_type.py @@ -13,6 +13,7 @@ # License for the specific language governing permissions and limitations # under the License. +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import utils @@ -20,6 +21,11 @@ from openstackclient.i18n import _ from openstackclient.network import sdk_utils +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { "type": "rule_type_name", @@ -65,5 +71,5 @@ class ShowNetworkQosRuleType(command.ShowOne): client = self.app.client_manager.network obj = client.get_qos_rule_type(parsed_args.rule_type) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return display_columns, data diff --git a/openstackclient/network/v2/network_rbac.py b/openstackclient/network/v2/network_rbac.py index 140c837e38..1781193f61 100644 --- a/openstackclient/network/v2/network_rbac.py +++ b/openstackclient/network/v2/network_rbac.py @@ -15,6 +15,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -27,6 +28,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): column_map = { 'target_tenant': 'target_project_id', @@ -136,7 +142,7 @@ class CreateNetworkRBAC(command.ShowOne): attrs = _get_attrs(self.app.client_manager, parsed_args) obj = client.create_rbac_policy(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return display_columns, data @@ -293,5 +299,5 @@ class ShowNetworkRBAC(command.ShowOne): obj = client.find_rbac_policy(parsed_args.rbac_policy, ignore_missing=False) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return display_columns, data diff --git a/openstackclient/network/v2/network_segment.py b/openstackclient/network/v2/network_segment.py index c1a672e2d5..5899dc697b 100644 --- a/openstackclient/network/v2/network_segment.py +++ b/openstackclient/network/v2/network_segment.py @@ -15,6 +15,7 @@ import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -26,6 +27,11 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _get_columns(item): return sdk_utils.get_osc_show_columns_for_sdk_resource(item, {}) @@ -90,7 +96,7 @@ class CreateNetworkSegment(command.ShowOne): attrs['segmentation_id'] = parsed_args.segment obj = client.create_segment(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) @@ -242,5 +248,5 @@ class ShowNetworkSegment(command.ShowOne): ignore_missing=False ) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) diff --git a/openstackclient/network/v2/network_segment_range.py b/openstackclient/network/v2/network_segment_range.py index b938bdd920..f03bcc1c0b 100644 --- a/openstackclient/network/v2/network_segment_range.py +++ b/openstackclient/network/v2/network_segment_range.py @@ -19,6 +19,7 @@ import itertools import logging +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import exceptions from osc_lib import utils @@ -31,6 +32,10 @@ from openstackclient.network import sdk_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + def _get_columns(item): return sdk_utils.get_osc_show_columns_for_sdk_resource(item, {}) @@ -212,7 +217,7 @@ class CreateNetworkSegmentRange(command.ShowOne): attrs['physical_network'] = parsed_args.physical_network obj = network_client.create_network_segment_range(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) data = _update_additional_fields_from_props(columns, props=data) return (display_columns, data) @@ -451,6 +456,6 @@ class ShowNetworkSegmentRange(command.ShowOne): ignore_missing=False ) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) data = _update_additional_fields_from_props(columns, props=data) return (display_columns, data) diff --git a/openstackclient/network/v2/port.py b/openstackclient/network/v2/port.py index e6bfe8537f..4d7e518975 100644 --- a/openstackclient/network/v2/port.py +++ b/openstackclient/network/v2/port.py @@ -51,6 +51,7 @@ _formatters = { 'dns_assignment': format_columns.ListDictColumn, 'extra_dhcp_opts': format_columns.ListDictColumn, 'fixed_ips': format_columns.ListDictColumn, + 'location': format_columns.DictColumn, 'security_group_ids': format_columns.ListColumn, 'tags': format_columns.ListColumn, } diff --git a/openstackclient/network/v2/router.py b/openstackclient/network/v2/router.py index 11b012e67e..02da50c38e 100644 --- a/openstackclient/network/v2/router.py +++ b/openstackclient/network/v2/router.py @@ -61,6 +61,7 @@ _formatters = { 'external_gateway_info': RouterInfoColumn, 'availability_zones': format_columns.ListColumn, 'availability_zone_hints': format_columns.ListColumn, + 'location': format_columns.DictColumn, 'routes': RoutesColumn, 'tags': format_columns.ListColumn, } diff --git a/openstackclient/network/v2/security_group.py b/openstackclient/network/v2/security_group.py index e389473828..38b4e97a80 100644 --- a/openstackclient/network/v2/security_group.py +++ b/openstackclient/network/v2/security_group.py @@ -16,6 +16,7 @@ import argparse from cliff import columns as cliff_columns +from osc_lib.cli import format_columns from osc_lib.command import command from osc_lib import utils import six @@ -77,11 +78,13 @@ class ComputeSecurityGroupRulesColumn(cliff_columns.FormattableColumn): _formatters_network = { + 'location': format_columns.DictColumn, 'security_group_rules': NetworkSecurityGroupRulesColumn, } _formatters_compute = { + 'location': format_columns.DictColumn, 'rules': ComputeSecurityGroupRulesColumn, } diff --git a/openstackclient/network/v2/security_group_rule.py b/openstackclient/network/v2/security_group_rule.py index dbea747300..15f099b1eb 100644 --- a/openstackclient/network/v2/security_group_rule.py +++ b/openstackclient/network/v2/security_group_rule.py @@ -16,6 +16,7 @@ import argparse import logging +from osc_lib.cli import format_columns from osc_lib.cli import parseractions from osc_lib import exceptions from osc_lib import utils @@ -31,6 +32,11 @@ from openstackclient.network import utils as network_utils LOG = logging.getLogger(__name__) +_formatters = { + 'location': format_columns.DictColumn, +} + + def _format_security_group_rule_show(obj): data = network_utils.transform_compute_security_group_rule(obj) return zip(*sorted(six.iteritems(data))) @@ -337,7 +343,7 @@ class CreateSecurityGroupRule(common.NetworkAndComputeShowOne): # Create and show the security group rule. obj = client.create_security_group_rule(**attrs) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) def take_action_compute(self, client, parsed_args): @@ -596,7 +602,7 @@ class ShowSecurityGroupRule(common.NetworkAndComputeShowOne): if not obj['remote_ip_prefix']: obj['remote_ip_prefix'] = _format_remote_ip_prefix(obj) display_columns, columns = _get_columns(obj) - data = utils.get_item_properties(obj, columns) + data = utils.get_item_properties(obj, columns, formatters=_formatters) return (display_columns, data) def take_action_compute(self, client, parsed_args): diff --git a/openstackclient/network/v2/subnet.py b/openstackclient/network/v2/subnet.py index 1f0c2d9478..c53688615f 100644 --- a/openstackclient/network/v2/subnet.py +++ b/openstackclient/network/v2/subnet.py @@ -61,6 +61,7 @@ _formatters = { 'allocation_pools': AllocationPoolsColumn, 'dns_nameservers': format_columns.ListColumn, 'host_routes': HostRoutesColumn, + 'location': format_columns.DictColumn, 'service_types': format_columns.ListColumn, 'tags': format_columns.ListColumn, } diff --git a/openstackclient/network/v2/subnet_pool.py b/openstackclient/network/v2/subnet_pool.py index 7ece263a36..d5a15475ef 100644 --- a/openstackclient/network/v2/subnet_pool.py +++ b/openstackclient/network/v2/subnet_pool.py @@ -42,6 +42,7 @@ def _get_columns(item): _formatters = { + 'location': format_columns.DictColumn, 'prefixes': format_columns.ListColumn, 'tags': format_columns.ListColumn, }