libvirt: improve error msg for host key value
The error message is unclear, omitting the key for the data in host definition. Test Plan: PASS regresion PASS unit test of code path Story: 2010816 Task: 48636 Change-Id: I90ca410c252f9ce14b8dd4c13affb592eac88d85 Signed-off-by: Michel Thebeau <michel.thebeau@windriver.com>
This commit is contained in:
parent
286f233a4b
commit
4079553a32
@ -135,8 +135,8 @@ def host_key_validate(data, field, value):
|
||||
errnum += 1
|
||||
elif key in ('cpu', 'mem'):
|
||||
if not isinstance(item, int):
|
||||
print('%s is not valid for %s' %
|
||||
(item, field), file=sys.stderr)
|
||||
print('%s is not valid for %s in %s' %
|
||||
(item, key, field), file=sys.stderr)
|
||||
errnum += 1
|
||||
return errnum
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user