qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 10/12] tests/qemu-iotests: Replace the words 'blacklist/white


From: Kevin Wolf
Subject: Re: [PATCH 10/12] tests/qemu-iotests: Replace the words 'blacklist/whitelist'
Date: Wed, 3 Feb 2021 16:41:33 +0100

Am 03.02.2021 um 11:28 hat Daniel P. Berrangé geschrieben:
> On Tue, Feb 02, 2021 at 09:58:22PM +0100, Philippe Mathieu-Daudé wrote:
> > Follow the inclusive terminology from the "Conscious Language in your
> > Open Source Projects" guidelines [*] and replace the words "blacklist"
> > and "whitelist" appropriately.

We're not doing access control here, so allowlist/denylist are not the
appropriate words to use here.

> > [*] https://github.com/conscious-lang/conscious-lang-docs/blob/main/faq.md
> > 
> > Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> > ---
> >  tests/qemu-iotests/149     | 14 +++++++-------
> >  tests/qemu-iotests/149.out |  8 ++++----
> >  2 files changed, 11 insertions(+), 11 deletions(-)
> > 
> > diff --git a/tests/qemu-iotests/149 b/tests/qemu-iotests/149
> > index 328fd05a4c9..b1d3f5fad67 100755
> > --- a/tests/qemu-iotests/149
> > +++ b/tests/qemu-iotests/149
> > @@ -500,7 +500,7 @@ configs = [
> >  
> >  ]
> >  
> > -blacklist = [
> > +denylist = [
> >      # We don't have a cast-6 cipher impl for QEMU yet
> >      "cast6-256-xts-plain64-sha1",
> >      "cast6-128-xts-plain64-sha1",
> > @@ -510,17 +510,17 @@ blacklist = [
> >      "twofish-192-xts-plain64-sha1",
> >  ]
> 
> "skiplist" better describes the purpose of this.

That it's a list is very obvious from the code and doesn't tell anything
about the content. How about skip_configs?

> >  
> > -whitelist = []
> > +allowlist = []
> >  if "LUKS_CONFIG" in os.environ:
> > -    whitelist = os.environ["LUKS_CONFIG"].split(",")
> > +    allowlist = os.environ["LUKS_CONFIG"].split(",")
> 
> And "filterlist"

test_configs? configs_to_test?

> >  
> >  for config in configs:
> > -    if config.name in blacklist:
> > -        iotests.log("Skipping %s in blacklist" % config.name)
> > +    if config.name in denylist:
> > +        iotests.log("Skipping %s in denylist" % config.name)
> >          continue
> >  
> > -    if len(whitelist) > 0 and config.name not in whitelist:
> > -        iotests.log("Skipping %s not in whitelist" % config.name)
> > +    if len(allowlist) > 0 and config.name not in allowlist:
> > +        iotests.log("Skipping %s not in allowlist" % config.name)
> >          continue

The messages need to be updates accordingly, of course.

Kevin




reply via email to

[Prev in Thread] Current Thread [Next in Thread]