qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Thomas Huth <thuth@redhat.com>
Cc: Markus Armbruster <armbru@redhat.com>,
	Eric Blake <eblake@redhat.com>,
	Roman Kagan <rkagan@virtuozzo.com>, Kevin Wolf <kwolf@redhat.com>,
	qemu-devel@nongnu.org, qemu-block@nongnu.org,
	Max Reitz <mreitz@redhat.com>,
	Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [Qemu-devel] [PATCH 03/17] iotests: ask qemu for supported formats
Date: Thu, 7 Jun 2018 13:42:02 +0100	[thread overview]
Message-ID: <20180607124202.GM28827@redhat.com> (raw)
In-Reply-To: <19326638-6980-5473-dea9-79c7aabdf710@redhat.com>

On Thu, Jun 07, 2018 at 09:50:41AM +0200, Thomas Huth wrote:
> On 07.06.2018 08:57, Markus Armbruster wrote:
> > Thomas Huth <thuth@redhat.com> writes:
> > 
> >> On 05.06.2018 00:40, Eric Blake wrote:
> >>> On 06/04/2018 05:34 AM, Thomas Huth wrote:
> >>>> On 04.06.2018 09:18, Markus Armbruster wrote:
> >>>>> Roman Kagan <rkagan@virtuozzo.com> writes:
> >>>>>
> >>>>>> Add helper functions to query the block drivers actually supported by
> >>>>>> QEMU using "-drive format=?".  This allows to skip certain tests that
> >>>>>> require drivers not built in or whitelisted in QEMU.
> >>>>>>
> >>>
> >>>>>> +    supported_formats=$($QEMU_PROG $QEMU_OPTIONS -drive format=\?
> >>>>>> 2>&1 | \
> >>>>>
> >>>>> Use of '?' to get help is deprecated.  Please use 'format=help', and
> >>>>> update your commit message accordingly.
> >>>>
> >>>> Is it? Where did we document that?
> >>>
> >>> Hmm, we haven't documented it yet, but it's been that way since commit
> >>> c8057f95, in Aug 2012, when we added 'help' as the preferred synonym,
> >>> and have tried to avoid mention of '?' in new documentation (as it
> >>> requires additional shell quoting).  I'm guessing we'll probably see a
> >>> patch from you to start an official deprecation window?
> >>
> >> I'm using '?' regularly on my own, so don't expect a patch from
> >> my side here ;-)
> >> Anyway, we still use the question mark in our documentation, e.g.:
> >>
> >> options
> >>
> >>     is a comma separated list of format specific options in a name=value format.
> >>     Use -o ? for an overview of the options supported by the used format or see
> >>     the format descriptions below for details.
> >>
> >> or:
> >>
> >> -b, --blacklist=list
> >>
> >>     Comma-separated list of RPCs to disable (no spaces, ‘?’ to list available RPCs)
> > 
> > These are bugs, and we need to fix them.
> > 
> >> So calling it deprecated sounds wrong to me.
> > 
> > Our intent to deprecate it was pretty clear in commit c8057f95:
> > 
> >     /**
> >      * is_help_option:
> >      * @s: string to test
> >      *
> >      * Check whether @s is one of the standard strings which indicate
> >      * that the user is asking for a list of the valid values for a
> >      * command option like -cpu or -M. The current accepted strings
> > -->  * are 'help' and '?'. '?' is deprecated (it is a shell wildcard
> >      * which makes it annoying to use in a reliable way) but provided
> >      * for backwards compatibility.
> >      *
> >      * Returns: true if @s is a request for a list.
> >      */
> >     static inline bool is_help_option(const char *s)
> > 
> > Predates today's more formal deprecation policy.  Simpler times.
> 
> Sure, but finding such messages in the sources can be quite cumbersome...
> 
> > There's no real need to kill off '?', unless it gets in the way of
> > steering people towards 'help'.  We should steer them toward 'help',
> > because '?' is a trap for insufficiently sophisticated users of
> > shell[*].
> 
> ... and I agree with your points here.
> 
> => I think we need a second list of deprecated feature (maybe we should
> call them "legacy features" instead of "deprecated"?), i.e. a list of
> features which we don't recommend for new code / scripts anymore, but
> which we do not intend to remove via our official deprecation policy any
> time soon. Things like "--enable-kvm" / "-no-kvm" or maybe even "-net"
> go into the same category.

I don't see much point to be honest. If --enable-kvm works for the user
and we're not intending to removal it, I don't see why they should care
about using something else instead.  The other thing might have a more
flexible syntax, but if they don't need those extra features it really
doesn't matter. IOW, I think it is sufficient to just document all the
options that exist, and when documenting them simply make a note inline
that a particular option is merely  syntax suger for an alternative
option.

Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|

  parent reply	other threads:[~2018-06-07 12:42 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-26 16:19 [Qemu-devel] [PATCH 00/17] iotests: don't choke on disabled drivers Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 01/17] block: iterate_format with account of whitelisting Roman Kagan
2018-04-26 18:15   ` Eric Blake
2018-05-30 12:03   ` Max Reitz
2018-04-26 16:19 ` [Qemu-devel] [PATCH 02/17] iotests: iotests.py: prevent deadlock in subprocess Roman Kagan
2018-05-30 12:07   ` Max Reitz
2018-04-26 16:19 ` [Qemu-devel] [PATCH 03/17] iotests: ask qemu for supported formats Roman Kagan
2018-05-30 12:17   ` Max Reitz
2018-05-30 13:07     ` Roman Kagan
2018-06-04  7:18   ` Markus Armbruster
2018-06-04 10:34     ` Thomas Huth
2018-06-04 22:40       ` Eric Blake
2018-06-05  4:02         ` Thomas Huth
2018-06-07  6:57           ` Markus Armbruster
2018-06-07  7:50             ` Thomas Huth
2018-06-07 11:07               ` Paolo Bonzini
2018-06-07 11:10                 ` Thomas Huth
2018-06-07 11:18                   ` Paolo Bonzini
2018-06-07 11:27                     ` [Qemu-devel] -enable-kvm and friens (was: Re: [PATCH 03/17] iotests: ask qemu for supported formats) Thomas Huth
2018-06-07 11:42                       ` Paolo Bonzini
2018-06-07 11:51                         ` [Qemu-devel] -enable-kvm and friens Thomas Huth
2018-06-07 11:29               ` [Qemu-devel] [PATCH 03/17] iotests: ask qemu for supported formats Markus Armbruster
2018-06-07 12:42               ` Daniel P. Berrangé [this message]
2018-04-26 16:19 ` [Qemu-devel] [PATCH 04/17] iotest 030: skip quorum test setup/teardown too Roman Kagan
2018-05-30 12:19   ` Max Reitz
2018-04-26 16:19 ` [Qemu-devel] [PATCH 05/17] iotest 030: require blkdebug Roman Kagan
2018-05-30 12:19   ` Max Reitz
2018-04-26 16:19 ` [Qemu-devel] [PATCH 06/17] iotest 055: skip unsupported backup target formats Roman Kagan
2018-05-30 12:22   ` Max Reitz
2018-04-26 16:19 ` [Qemu-devel] [PATCH 07/17] iotest 055: require blkdebug Roman Kagan
2018-05-30 12:22   ` Max Reitz
2018-04-26 16:19 ` [Qemu-devel] [PATCH 08/17] iotest 056: skip testcases using blkdebug if disabled Roman Kagan
2018-05-30 12:26   ` Max Reitz
2018-04-26 16:19 ` [Qemu-devel] [PATCH 09/17] iotest 071: notrun if blkdebug or blkverify is disabled Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 10/17] iotest 081: notrun if quorum " Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 11/17] iotest 087: notrun if null-co " Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 12/17] iotest 093: notrun if null-co or null-aio " Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 13/17] iotest 099: notrun if blkdebug or blkverify " Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 14/17] iotest 124: skip testcases using blkdebug if disabled Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 15/17] iotest 139: skip testcases using disabled drivers Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 16/17] iotest 147: notrun if nbd is disabled Roman Kagan
2018-04-26 16:19 ` [Qemu-devel] [PATCH 17/17] iotest 184: notrun if null-co or throttle " Roman Kagan
2018-04-26 16:47 ` [Qemu-devel] [PATCH 00/17] iotests: don't choke on disabled drivers no-reply
2018-05-17 16:11 ` [Qemu-devel] [Qemu-block] " Roman Kagan
2018-05-30 12:35 ` [Qemu-devel] " Max Reitz
2018-05-30 13:47   ` Roman Kagan
2018-05-30 13:53     ` Max Reitz
2018-05-30 14:16       ` Roman Kagan

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=20180607124202.GM28827@redhat.com \
    --to=berrange@redhat.com \
    --cc=armbru@redhat.com \
    --cc=eblake@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=rkagan@virtuozzo.com \
    --cc=thuth@redhat.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).