[PULL 0/5] QAPI patches patches for 2023-05-17

Markus Armbruster posted 5 patches 11 months, 3 weeks ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20230517152516.1884640-1-armbru@redhat.com
Maintainers: Markus Armbruster <armbru@redhat.com>, Michael Roth <michael.roth@amd.com>, John Snow <jsnow@redhat.com>, Cleber Rosa <crosa@redhat.com>, Beraldo Leal <bleal@redhat.com>, Eric Blake <eblake@redhat.com>
There is a newer version of this series
docs/devel/qapi-code-gen.rst                  |   3 +-
docs/interop/index.rst                        |   1 +
docs/interop/qmp-intro.txt                    |  88 -------
docs/interop/{qmp-spec.txt => qmp-spec.rst}   | 337 ++++++++++++++------------
qapi/control.json                             |   4 +-
qapi/qapi-schema.json                         |   3 +-
qobject/json-lexer.c                          |   2 +-
python/qemu/qmp/models.py                     |   8 +-
python/qemu/qmp/qmp_client.py                 |   4 +-
qemu-options.hx                               |  28 ++-
scripts/qapi/parser.py                        |   8 +-
tests/qapi-schema/doc-interleaved-section.err |   2 +-
12 files changed, 226 insertions(+), 262 deletions(-)
delete mode 100644 docs/interop/qmp-intro.txt
rename docs/interop/{qmp-spec.txt => qmp-spec.rst} (55%)
[PULL 0/5] QAPI patches patches for 2023-05-17
Posted by Markus Armbruster 11 months, 3 weeks ago
The following changes since commit f9d58e0ca53b3f470b84725a7b5e47fcf446a2ea:

  Merge tag 'pull-9p-20230516' of https://github.com/cschoenebeck/qemu into staging (2023-05-16 10:21:44 -0700)

are available in the Git repository at:

  https://repo.or.cz/qemu/armbru.git tags/pull-qapi-2023-05-17

for you to fetch changes up to 28d2a4f620db2bc327dbd3443b777890d39a0bf6:

  qapi/parser: Drop two bad type hints for now (2023-05-17 15:49:22 +0200)

----------------------------------------------------------------
QAPI patches patches for 2023-05-17

----------------------------------------------------------------
Markus Armbruster (2):
      qapi: Improve error message for description following section
      qapi/parser: Drop two bad type hints for now

Peter Maydell (3):
      docs/interop: Convert qmp-spec.txt to rST
      docs/interop/qmp-spec: Update error description for parsing errors
      docs/interop: Delete qmp-intro.txt

 docs/devel/qapi-code-gen.rst                  |   3 +-
 docs/interop/index.rst                        |   1 +
 docs/interop/qmp-intro.txt                    |  88 -------
 docs/interop/{qmp-spec.txt => qmp-spec.rst}   | 337 ++++++++++++++------------
 qapi/control.json                             |   4 +-
 qapi/qapi-schema.json                         |   3 +-
 qobject/json-lexer.c                          |   2 +-
 python/qemu/qmp/models.py                     |   8 +-
 python/qemu/qmp/qmp_client.py                 |   4 +-
 qemu-options.hx                               |  28 ++-
 scripts/qapi/parser.py                        |   8 +-
 tests/qapi-schema/doc-interleaved-section.err |   2 +-
 12 files changed, 226 insertions(+), 262 deletions(-)
 delete mode 100644 docs/interop/qmp-intro.txt
 rename docs/interop/{qmp-spec.txt => qmp-spec.rst} (55%)

-- 
2.39.2
Re: [PULL 0/5] QAPI patches patches for 2023-05-17
Posted by Richard Henderson 11 months, 3 weeks ago
On 5/17/23 08:25, Markus Armbruster wrote:
> The following changes since commit f9d58e0ca53b3f470b84725a7b5e47fcf446a2ea:
> 
>    Merge tag 'pull-9p-20230516' of https://github.com/cschoenebeck/qemu into staging (2023-05-16 10:21:44 -0700)
> 
> are available in the Git repository at:
> 
>    https://repo.or.cz/qemu/armbru.git tags/pull-qapi-2023-05-17
> 
> for you to fetch changes up to 28d2a4f620db2bc327dbd3443b777890d39a0bf6:
> 
>    qapi/parser: Drop two bad type hints for now (2023-05-17 15:49:22 +0200)
> 
> ----------------------------------------------------------------
> QAPI patches patches for 2023-05-17

Multiple failures:

https://gitlab.com/qemu-project/qemu/-/jobs/4303506112#L4674

▶  2/61 /x86_64/migration/multifd/tcp/tls/x509/default-host - 
ERROR:../tests/qtest/migration-helpers.c:180:check_migration_status: assertion failed 
(current_status != "failed"): ("failed" != "failed") FAIL


https://gitlab.com/qemu-project/qemu/-/jobs/4303506102#L3766
https://gitlab.com/qemu-project/qemu/-/jobs/4303506050#L5856
https://gitlab.com/qemu-project/qemu/-/jobs/4303506047#L3654

/home/gitlab-runner/builds/Jpwtyaz7/0/qemu-project/qemu/docs/interop/qmp-spec.rst:71:Error 
in "code-block" directive:
1 argument(s) required, 0 supplied.
.. code-block::
   { "QMP": { "version": json-object, "capabilities": json-array } }


r~

Re: [PULL 0/5] QAPI patches patches for 2023-05-17
Posted by Peter Maydell 11 months, 3 weeks ago
On Wed, 17 May 2023 at 18:16, Richard Henderson
<richard.henderson@linaro.org> wrote:
> https://gitlab.com/qemu-project/qemu/-/jobs/4303506102#L3766
> https://gitlab.com/qemu-project/qemu/-/jobs/4303506050#L5856
> https://gitlab.com/qemu-project/qemu/-/jobs/4303506047#L3654
>
> /home/gitlab-runner/builds/Jpwtyaz7/0/qemu-project/qemu/docs/interop/qmp-spec.rst:71:Error
> in "code-block" directive:
> 1 argument(s) required, 0 supplied.
> .. code-block::
>    { "QMP": { "version": json-object, "capabilities": json-array } }

Looks like whatever version of Sphinx this is enforces that
code-block comments specify a language. The system I tested on
didn't care.

In theory these blocks should be ".. code-block:: json", you
might think, but for me that results in

Warning, treated as error:
/mnt/nvmedisk/linaro/qemu-from-laptop/qemu/docs/interop/qmp-spec.rst:71:Could
not lex literal_block as "json". Highlighting skipped.

(which I think means my system doesn't have the json lexer,
but who knows...)

So the simplest fix is to turn all the no-language code-blocks into
plain old literal blocks (the ones which are "QMP" format are fine,
but specifying QMP doesn't work for these blocks, because the QMP lexer
insists on seeing the -> and <- that indicate a command/response
direction). This should work as a fixup to the patch.

Markus, could I ask you to squash it in for the next round of this pullreq ?

diff --git a/docs/interop/qmp-spec.rst b/docs/interop/qmp-spec.rst
index 2609b3ff9b2..23ddcc853e5 100644
--- a/docs/interop/qmp-spec.rst
+++ b/docs/interop/qmp-spec.rst
@@ -68,7 +68,7 @@ ready for capabilities negotiation (for more
information refer to section

 The greeting message format is:

-.. code-block::
+::

   { "QMP": { "version": json-object, "capabilities": json-array } }

@@ -94,13 +94,13 @@ Issuing Commands

 The format for command execution is:

-.. code-block::
+::

   { "execute": json-string, "arguments": json-object, "id": json-value }

 or

-.. code-block::
+::

   { "exec-oob": json-string, "arguments": json-object, "id": json-value }

@@ -164,7 +164,7 @@ Success

 The format of a success response is:

-.. code-block::
+::

   { "return": json-value, "id": json-value }

@@ -183,7 +183,7 @@ Error

 The format of an error response is:

-.. code-block::
+::

   { "error": { "class": json-string, "desc": json-string }, "id": json-value }

@@ -208,7 +208,7 @@ response. They are called "asynchronous events".

 The format of asynchronous events is:

-.. code-block::
+::

   { "event": json-string, "data": json-object,
     "timestamp": { "seconds": json-number, "microseconds": json-number } }

thanks
-- PMM