]> git.ipfire.org Git - thirdparty/qemu.git/commit
python/machine.py: Add _qmp access shim
authorJohn Snow <jsnow@redhat.com>
Tue, 6 Oct 2020 23:58:04 +0000 (19:58 -0400)
committerJohn Snow <jsnow@redhat.com>
Tue, 20 Oct 2020 13:37:57 +0000 (09:37 -0400)
commitbe1183e52f49cd0f9c1a855afe4c4a5455f966d1
treef14d28110ed8222b9f59c72b3cfbeb1ee08988ba
parentaaa81ec6093b2d45d5a318227db82fa71680a871
python/machine.py: Add _qmp access shim

Like many other Optional[] types, it's not always a given that this
object will be set. Wrap it in a type-shim that raises a meaningful
error and will always return a concrete type.

Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Message-id: 20201006235817.3280413-8-jsnow@redhat.com
Signed-off-by: John Snow <jsnow@redhat.com>
python/qemu/machine.py