Skip to content

Commit fc4b592

Browse files
robertbrekermelwitt
authored andcommitted
Fix nova-manage image_property show unexpected keyword
Reproduction steps: 1. Execute: nova-manage image_property show <vm_uuid> \ hw_vif_multiqueue_enabled 2. Observe: An error has occurred: Traceback (most recent call last): File "/var/lib/kolla/venv/lib/python3.9/ site-packages/nova/cmd/manage.py", line 3394, in main ret = fn(*fn_args, **fn_kwargs) TypeError: show() got an unexpected keyword argument 'property' Change-Id: I1349b880934ad9f44a943cf7de324d7338619d2e Closes-Bug: #2016346 (cherry picked from commit 1c02c0d)
1 parent ae003e7 commit fc4b592

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

nova/cmd/manage.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3276,7 +3276,7 @@ class ImagePropertyCommands:
32763276
'instance_uuid', metavar='<instance_uuid>',
32773277
help='UUID of the instance')
32783278
@args(
3279-
'property', metavar='<image_property>',
3279+
'image_property', metavar='<image_property>',
32803280
help='Image property to show')
32813281
def show(self, instance_uuid=None, image_property=None):
32823282
"""Show value of a given instance image property.
@@ -3294,10 +3294,10 @@ def show(self, instance_uuid=None, image_property=None):
32943294
with context.target_cell(ctxt, im.cell_mapping) as cctxt:
32953295
instance = objects.Instance.get_by_uuid(
32963296
cctxt, instance_uuid, expected_attrs=['system_metadata'])
3297-
image_property = instance.system_metadata.get(
3297+
property_value = instance.system_metadata.get(
32983298
f'image_{image_property}')
3299-
if image_property:
3300-
print(image_property)
3299+
if property_value:
3300+
print(property_value)
33013301
return 0
33023302
else:
33033303
print(f'Image property {image_property} not found '

0 commit comments

Comments
 (0)