vici: Decode error messages in Python bindings
Otherwise we might end up with b'<errmsg>' in the output.
This commit is contained in:
parent
414f2c3754
commit
2610cd7928
|
@ -78,7 +78,7 @@ class Session(CommandWrappers, object):
|
|||
if command_response["success"] != b"yes":
|
||||
raise CommandException(
|
||||
"Command failed: {errmsg}".format(
|
||||
errmsg=command_response["errmsg"]
|
||||
errmsg=command_response["errmsg"].decode("UTF-8")
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -135,7 +135,7 @@ class Session(CommandWrappers, object):
|
|||
if command_response["success"] != b"yes":
|
||||
raise CommandException(
|
||||
"Command failed: {errmsg}".format(
|
||||
errmsg=command_response["errmsg"]
|
||||
errmsg=command_response["errmsg"].decode("UTF-8")
|
||||
)
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in New Issue