aboutsummaryrefslogtreecommitdiff
path: root/python/qemu/qtest.py
diff options
context:
space:
mode:
authorJohn Snow <jsnow@redhat.com>2020-07-10 01:22:08 -0400
committerPhilippe Mathieu-Daudé <philmd@redhat.com>2020-07-14 22:22:22 +0200
commitef5d474472426eda6abf8128cdb1d026af94862b (patch)
tree8466eafbd5846a9d4882d4a27d492d64d929c4b5 /python/qemu/qtest.py
parente3a23b4803a3939c7e24e8946880f5ef369ef781 (diff)
downloadqemu-ef5d474472426eda6abf8128cdb1d026af94862b.zip
qemu-ef5d474472426eda6abf8128cdb1d026af94862b.tar.gz
qemu-ef5d474472426eda6abf8128cdb1d026af94862b.tar.bz2
python/qmp.py: Do not return None from cmd_obj
This makes typing the qmp library difficult, as it necessitates wrapping Optional[] around the type for every return type up the stack. At some point, it becomes difficult to discern or remember why it's None instead of the expected object. Use the python exception system to tell us exactly why we didn't get an object. Remove this special-cased return. Signed-off-by: John Snow <jsnow@redhat.com> Reviewed-by: Kevin Wolf <kwolf@redhat.com> Message-Id: <20200710052220.3306-5-jsnow@redhat.com> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Diffstat (limited to 'python/qemu/qtest.py')
0 files changed, 0 insertions, 0 deletions