All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: "John Snow" <jsnow@redhat.com>,
	qemu-devel@nongnu.org, "Alex Williamson" <alex@shazbot.org>,
	linux-cxl@vger.kernel.org, "Michael Tokarev" <mjt@tls.msk.ru>,
	"Vladimir Sementsov-Ogievskiy" <vsementsov@yandex-team.ru>,
	"Peter Xu" <peterx@redhat.com>, "Eric Blake" <eblake@redhat.com>,
	"Marc-André Lureau" <marcandre.lureau@redhat.com>,
	"zhenwei pi" <zhenwei.pi@linux.dev>,
	qemu-trivial@nongnu.org, "Fabiano Rosas" <farosas@suse.de>,
	"Kevin Wolf" <kwolf@redhat.com>,
	"Laurent Vivier" <laurent@vivier.eu>,
	"Jiri Pirko" <jiri@resnulli.us>,
	qemu-block@nongnu.org, "Stefan Hajnoczi" <stefanha@redhat.com>,
	"Stefan Berger" <stefanb@linux.vnet.ibm.com>,
	linux-edac@vger.kernel.org,
	"Gonglei (Arei)" <arei.gonglei@huawei.com>,
	"Igor Mammedov" <imammedo@redhat.com>,
	"Gerd Hoffmann" <kraxel@redhat.com>,
	"Jonathan Cameron" <jic23@kernel.org>,
	"Alex Bennée" <alex.bennee@linaro.org>,
	"Zhao Liu" <zhao1.liu@intel.com>,
	"Mauro Carvalho Chehab" <mchehab+huawei@kernel.org>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	"Hanna Reitz" <hreitz@redhat.com>,
	"Jason Wang" <jasowangio@gmail.com>,
	"Richard Henderson" <richard.henderson@linaro.org>,
	"Paolo Bonzini" <pbonzini@redhat.com>,
	"Ani Sinha" <anisinha@redhat.com>,
	"Philippe Mathieu-Daudé" <philmd@mailo.com>,
	"Lukas Straub" <lukasstraub2@web.de>,
	"Cédric Le Goater" <clg@redhat.com>
Subject: Re: [PATCH v3 01/43] qapi: convert trivial intro sections for error.json
Date: Thu, 27 Aug 2026 14:39:23 +0100	[thread overview]
Message-ID: <apA-CzGqrlFNfjp5@redhat.com> (raw)
In-Reply-To: <87jypb90c0.fsf@pond.sub.org>

On Thu, Aug 27, 2026 at 03:09:35PM +0200, Markus Armbruster wrote:
> Daniel P. Berrangé <berrange@redhat.com> writes:
> 
> > On Wed, Aug 26, 2026 at 03:37:58PM -0400, John Snow wrote:
> >> Signed-off-by: John Snow <jsnow@redhat.com>
> >> ---
> >>  qapi/error.json | 3 +--
> >>  1 file changed, 1 insertion(+), 2 deletions(-)
> >> 
> >> diff --git a/qapi/error.json b/qapi/error.json
> >> index 54cb02fb880..a53b13e55c9 100644
> >> --- a/qapi/error.json
> >> +++ b/qapi/error.json
> >> @@ -9,8 +9,7 @@
> >>  
> >>  ##
> >>  # @QapiErrorClass:
> >> -#
> >> -# QEMU error classes
> >> +#     QEMU error classes
> >
> > Where is this need for indent coming from ?  From the POV of someone
> > writing comments, the need to indent the introductory text like this
> > feels very counter-intuitive, an exception from any other inline
> > docs syntax I've typically used. Is there any way we can avoid this ?
> 
> The cover letter explains the need:

Yes, I just didn't see the connection from that, to the use
of indent.

> 
>     This is being done primarily for the benefit of the forthcoming
>     "inliner", a feature for the rendered HTML QMP documentation that
>     seeks to "inline" QMP command argument documentation into the argument
>     list for each command.
> 
>     There are two main motives here:
> 
>     (1) We want the split between the "introduction" and "details"
>         sections to be mechanically obvious, so that auto-generated or
>         inlined documentation has a well-defined, obvious spot to go.
> 
>     (2) We do not want to inline irrelevant, introductory text describing
>         structures to be copied into command documentation.

So IIUC, you're saying that we are going to rely on indentation
to distinguish introduction from details ?


> Note that the inliner elided Netdev's Intro "Captures the configuration
> of a network device."
> 
> However, when Intro and Details bleed together, the inliner elides more
> than it should.  I consider that a fairly serious issue.
> 
> I'm afraid forgetting to mark the end of Intro with "Details:" would be
> a common mistake, easy to miss in review.  So I explored possible
> alternatives:
> 
>     Subject: Re: [PATCH v2 00/10] qapi: enforce section ordering
>     Date: Wed, 15 Apr 2026 11:43:45 +0200
>     Message-ID: <87zf341ru6.fsf@pond.sub.org>
>     https://lore.kernel.org/qemu-devel/87zf341ru6.fsf@pond.sub.org/
> 
> John is working towards "3. Make the end of intro syntactically obvious"
> always, specifically "3c. Indent intro like descriptions and tagged
> sections" with the ultimate goal to reject unindented Intro.  That way,
> we cannot write an Intro with an unclear end.  John, correct me if I'm
> accidentally misrepresenting your work.
> 
> Questions?  Better ideas?

As an author, how substantive is "Intro" expected to be? I guess on
QAPI docs I've written I've not ever been aware of there even being
a distinct concept of Intro vs Details to think about. It is all just
some lines of prose to me.

My only alternative idea to indentation would be to declare that the
"Intro" is always the 1st paragraph of text and anything beyond that
is the "Details". That might match up with the way that contributors
naturally write text where the 1st paragraph conveys the key idea,
such that they dno't need to think about Intro vs Details as a
concept.

With regards,
Daniel
-- 
|: https://berrange.com       ~~        https://hachyderm.io/@berrange :|
|: https://libvirt.org          ~~          https://entangle-photo.org :|
|: https://pixelfed.art/berrange   ~~    https://fstop138.berrange.com :|


  reply	other threads:[~2026-08-27 13:39 UTC|newest]

Thread overview: 63+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-26 19:37 [PATCH v3 00/43] qapi: convert (very) trivial intro sections John Snow
2026-08-26 19:37 ` [PATCH v3 01/43] qapi: convert trivial intro sections for error.json John Snow
2026-08-27  8:43   ` Philippe Mathieu-Daudé
2026-08-27  9:10   ` Daniel P. Berrangé
2026-08-27 13:09     ` Markus Armbruster
2026-08-27 13:39       ` Daniel P. Berrangé [this message]
2026-08-31 18:43         ` John Snow
2026-09-01 10:09           ` Markus Armbruster
2026-08-26 19:37 ` [PATCH v3 02/43] qapi: convert trivial intro sections for acpi-hest.json John Snow
2026-08-26 19:38 ` [PATCH v3 03/43] qapi: convert trivial intro sections for ebpf.json John Snow
2026-08-26 19:38 ` [PATCH v3 04/43] qapi: convert trivial intro sections for compat.json John Snow
2026-08-26 19:38 ` [PATCH v3 05/43] qapi: convert trivial intro sections for vfio.json John Snow
2026-08-31 14:07   ` Cédric Le Goater
2026-08-26 19:38 ` [PATCH v3 06/43] qapi: convert trivial intro sections for trace.json John Snow
2026-08-26 19:38 ` [PATCH v3 07/43] qapi: convert trivial intro sections for misc-arm.json John Snow
2026-08-26 19:38 ` [PATCH v3 08/43] qapi: convert trivial intro sections for cryptodev.json John Snow
2026-08-26 19:38 ` [PATCH v3 09/43] qapi: convert trivial intro sections for machine-common.json John Snow
2026-08-26 19:38 ` [PATCH v3 10/43] qapi: convert trivial intro sections for accelerator.json John Snow
2026-08-27  8:39   ` Philippe Mathieu-Daudé
2026-08-26 19:38 ` [PATCH v3 11/43] qapi: convert trivial intro sections for authz.json John Snow
2026-08-26 19:38 ` [PATCH v3 12/43] qapi: convert trivial intro sections for yank.json John Snow
2026-08-26 19:38 ` [PATCH v3 13/43] qapi: convert trivial intro sections for replay.json John Snow
2026-08-26 19:38 ` [PATCH v3 14/43] qapi: convert trivial intro sections for machine-s390x.json John Snow
2026-08-26 19:38 ` [PATCH v3 15/43] qapi: convert trivial intro sections for acpi.json John Snow
2026-08-26 19:38 ` [PATCH v3 16/43] qapi: convert trivial intro sections for tpm.json John Snow
2026-08-26 19:38 ` [PATCH v3 17/43] qapi: convert trivial intro sections for qdev.json John Snow
2026-08-27  8:39   ` Philippe Mathieu-Daudé
2026-08-26 19:38 ` [PATCH v3 18/43] qapi: convert trivial intro sections for control.json John Snow
2026-08-26 19:38 ` [PATCH v3 19/43] qapi: convert trivial intro sections for dump.json John Snow
2026-08-26 19:38 ` [PATCH v3 20/43] qapi: convert trivial intro sections for common.json John Snow
2026-08-26 19:38 ` [PATCH v3 21/43] qapi: convert trivial intro sections for sockets.json John Snow
2026-08-26 19:38 ` [PATCH v3 22/43] qapi: convert trivial intro sections for transaction.json John Snow
2026-08-26 19:38 ` [PATCH v3 23/43] qapi: convert trivial intro sections for stats.json John Snow
2026-08-26 19:38 ` [PATCH v3 24/43] qapi: convert trivial intro sections for job.json John Snow
2026-08-26 19:38 ` [PATCH v3 25/43] qapi: convert trivial intro sections for pci.json John Snow
2026-08-27  8:40   ` Philippe Mathieu-Daudé
2026-08-26 19:38 ` [PATCH v3 26/43] qapi: convert trivial intro sections for introspect.json John Snow
2026-08-26 19:38 ` [PATCH v3 27/43] qapi: convert trivial intro sections for rocker.json John Snow
2026-08-26 19:38 ` [PATCH v3 28/43] qapi: convert trivial intro sections for misc-i386.json John Snow
2026-08-26 19:38 ` [PATCH v3 29/43] qapi: convert trivial intro sections for block-export.json John Snow
2026-08-26 19:38 ` [PATCH v3 30/43] qapi: convert trivial intro sections for audio.json John Snow
2026-08-26 19:38 ` [PATCH v3 31/43] qapi: convert trivial intro sections for block.json John Snow
2026-08-31 13:52   ` Markus Armbruster
2026-08-31 18:55     ` John Snow
2026-08-26 19:38 ` [PATCH v3 32/43] qapi: convert trivial intro sections for misc.json John Snow
2026-08-26 19:38 ` [PATCH v3 33/43] qapi: convert trivial intro sections for crypto.json John Snow
2026-08-26 19:38 ` [PATCH v3 34/43] qapi: convert trivial intro sections for cxl.json John Snow
2026-08-26 19:38 ` [PATCH v3 35/43] qapi: convert trivial intro sections for run-state.json John Snow
2026-08-27  8:41   ` Philippe Mathieu-Daudé
2026-08-26 19:38 ` [PATCH v3 36/43] qapi: convert trivial intro sections for char.json John Snow
2026-08-26 19:38 ` [PATCH v3 37/43] qapi: convert trivial intro sections for virtio.json John Snow
2026-08-26 19:38 ` [PATCH v3 38/43] qapi: convert trivial intro sections for net.json John Snow
2026-08-26 19:38 ` [PATCH v3 39/43] qapi: convert trivial intro sections for qom.json John Snow
2026-08-27  8:42   ` Philippe Mathieu-Daudé
2026-08-26 19:38 ` [PATCH v3 40/43] qapi: convert trivial intro sections for ui.json John Snow
2026-08-26 19:38 ` [PATCH v3 41/43] qapi: convert trivial intro sections for migration.json John Snow
2026-08-26 19:38 ` [PATCH v3 42/43] qapi: convert trivial intro sections for machine.json John Snow
2026-08-27  8:42   ` Philippe Mathieu-Daudé
2026-08-31 13:36   ` Markus Armbruster
2026-08-31 13:50     ` Markus Armbruster
2026-08-26 19:38 ` [PATCH v3 43/43] qapi: convert trivial intro sections for block-core.json John Snow
2026-08-31 13:32   ` Markus Armbruster
2026-08-31 14:27 ` [PATCH v3 00/43] qapi: convert (very) trivial intro sections Markus Armbruster

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=apA-CzGqrlFNfjp5@redhat.com \
    --to=berrange@redhat.com \
    --cc=alex.bennee@linaro.org \
    --cc=alex@shazbot.org \
    --cc=anisinha@redhat.com \
    --cc=arei.gonglei@huawei.com \
    --cc=armbru@redhat.com \
    --cc=clg@redhat.com \
    --cc=eblake@redhat.com \
    --cc=farosas@suse.de \
    --cc=hreitz@redhat.com \
    --cc=imammedo@redhat.com \
    --cc=jasowangio@gmail.com \
    --cc=jic23@kernel.org \
    --cc=jiri@resnulli.us \
    --cc=jsnow@redhat.com \
    --cc=kraxel@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=laurent@vivier.eu \
    --cc=linux-cxl@vger.kernel.org \
    --cc=linux-edac@vger.kernel.org \
    --cc=lukasstraub2@web.de \
    --cc=marcandre.lureau@redhat.com \
    --cc=mchehab+huawei@kernel.org \
    --cc=mjt@tls.msk.ru \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peterx@redhat.com \
    --cc=philmd@mailo.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@nongnu.org \
    --cc=richard.henderson@linaro.org \
    --cc=stefanb@linux.vnet.ibm.com \
    --cc=stefanha@redhat.com \
    --cc=vsementsov@yandex-team.ru \
    --cc=zhao1.liu@intel.com \
    --cc=zhenwei.pi@linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.