aboutsummaryrefslogtreecommitdiff
path: root/python/qemu/qmp
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2023-05-15 17:22:43 +0100
committerMarkus Armbruster <armbru@redhat.com>2023-05-22 10:21:01 +0200
commitd56572584d9a5414c6a55c3f6b7ecce4b098926b (patch)
tree95714599acc2811df158237c26efedfa9ef69395 /python/qemu/qmp
parent290e48e8f1ec975c100520fb697b0ae7300d0fb3 (diff)
downloadqemu-d56572584d9a5414c6a55c3f6b7ecce4b098926b.zip
qemu-d56572584d9a5414c6a55c3f6b7ecce4b098926b.tar.gz
qemu-d56572584d9a5414c6a55c3f6b7ecce4b098926b.tar.bz2
docs/interop: Convert qmp-spec.txt to rST
Convert the qmp-spec.txt document to restructuredText. Notable points about the conversion: * numbers at the start of section headings are removed, to match the style of the rest of the manual * cross-references to other sections or documents are hyperlinked * various formatting tweaks (notably the examples, which need the -> and <- prefixed so the QMP code-block lexer will accept them) * English prose fixed in a few places Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Message-Id: <20230515162245.3964307-2-peter.maydell@linaro.org> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> [.. code-block:: dumbed down to :: to work around CI failure]
Diffstat (limited to 'python/qemu/qmp')
-rw-r--r--python/qemu/qmp/models.py8
-rw-r--r--python/qemu/qmp/qmp_client.py4
2 files changed, 6 insertions, 6 deletions
diff --git a/python/qemu/qmp/models.py b/python/qemu/qmp/models.py
index de87f87..da52848 100644
--- a/python/qemu/qmp/models.py
+++ b/python/qemu/qmp/models.py
@@ -54,7 +54,7 @@ class Model:
class Greeting(Model):
"""
- Defined in qmp-spec.txt, section 2.2, "Server Greeting".
+ Defined in qmp-spec.rst, section "Server Greeting".
:param raw: The raw Greeting object.
:raise KeyError: If any required fields are absent.
@@ -82,7 +82,7 @@ class Greeting(Model):
class QMPGreeting(Model):
"""
- Defined in qmp-spec.txt, section 2.2, "Server Greeting".
+ Defined in qmp-spec.rst, section "Server Greeting".
:param raw: The raw QMPGreeting object.
:raise KeyError: If any required fields are absent.
@@ -104,7 +104,7 @@ class QMPGreeting(Model):
class ErrorResponse(Model):
"""
- Defined in qmp-spec.txt, section 2.4.2, "error".
+ Defined in qmp-spec.rst, section "Error".
:param raw: The raw ErrorResponse object.
:raise KeyError: If any required fields are absent.
@@ -126,7 +126,7 @@ class ErrorResponse(Model):
class ErrorInfo(Model):
"""
- Defined in qmp-spec.txt, section 2.4.2, "error".
+ Defined in qmp-spec.rst, section "Error".
:param raw: The raw ErrorInfo object.
:raise KeyError: If any required fields are absent.
diff --git a/python/qemu/qmp/qmp_client.py b/python/qemu/qmp/qmp_client.py
index 9d73ae6..2a817f9 100644
--- a/python/qemu/qmp/qmp_client.py
+++ b/python/qemu/qmp/qmp_client.py
@@ -369,7 +369,7 @@ class QMPClient(AsyncProtocol[Message], Events):
# This is very likely a server parsing error.
# It doesn't inherently belong to any pending execution.
# Instead of performing clever recovery, just terminate.
- # See "NOTE" in qmp-spec.txt, section 2.4.2
+ # See "NOTE" in qmp-spec.rst, section "Error".
raise ServerParseError(
("Server sent an error response without an ID, "
"but there are no ID-less executions pending. "
@@ -377,7 +377,7 @@ class QMPClient(AsyncProtocol[Message], Events):
msg
)
- # qmp-spec.txt, section 2.4:
+ # qmp-spec.rst, section "Commands Responses":
# 'Clients should drop all the responses
# that have an unknown "id" field.'
self.logger.log(