mirror of
https://github.com/virt-manager/virt-manager.git
synced 2024-12-23 17:34:21 +03:00
cli: Fix introspection for non-virt options
Like --location and --check
This commit is contained in:
parent
2a30a5f0bf
commit
4142b73c71
@ -717,7 +717,7 @@ c.add_invalid("--paravirt --import --print-xml 2") # PV Import install, no seco
|
||||
|
||||
c = vinst.add_category("misc-install", "--nographics --noautoconsole")
|
||||
c.add_compare("", "noargs-fail", auto_printarg=False) # No arguments
|
||||
c.add_valid("--panic help --disk=?") # Make sure introspection doesn't blow up
|
||||
c.add_valid("--panic help --disk=? --check=help", grep="path_in_use") # Make sure introspection doesn't blow up
|
||||
c.add_valid("--test-stub-command") # --test-stub-command
|
||||
c.add_valid("--nodisks --pxe", grep="VM performance may suffer") # os variant warning
|
||||
c.add_invalid("--hvm --nodisks --pxe foobar") # Positional arguments error
|
||||
|
@ -3189,7 +3189,9 @@ def check_option_introspection(options):
|
||||
Check if the user requested option introspection with ex: '--disk=?'
|
||||
"""
|
||||
ret = False
|
||||
for parserclass in VIRT_PARSERS:
|
||||
for parserclass in _get_completer_parsers():
|
||||
if not hasattr(options, parserclass.cli_arg_name):
|
||||
continue
|
||||
optlist = util.listify(getattr(options, parserclass.cli_arg_name))
|
||||
if not optlist:
|
||||
continue
|
||||
|
Loading…
Reference in New Issue
Block a user