On Tue, Jan 26, 2021 at 1:26 AM Antoine Pitrou <anto...@python.org> wrote:

> On Tue, 26 Jan 2021 10:36:10 +1100
> Steven D'Aprano <st...@pearwood.info> wrote:
> > On Mon, Jan 25, 2021 at 06:17:09PM +0100, Victor Stinner wrote:
> > > Hi Bernat,
> > >
> > > "stdlib_module_names" was my first idea but it looks too long, so I
> > > chose "module_names". But someone on Twitter and now you asked me why
> > > not "stdlib_module_names", so I wrote a PR to rename module_names to
> > > sys.stdlib_module_names:
> > > https://github.com/python/cpython/pull/24332
> > >
> > > At least "stdlib_module_names" better summarizes its definition: "A
> > > frozenset of strings containing the names of standard library
> > > modules".
> >
> > Your first instinct that it is too long is correct.
>
> Disagreed.  This is niche enough that it warrants a long but explicit
> name, rather than some ambiguous shortcut.
>

I agree w/ Antoine that a more descriptive name for such a niche (but
useful!) attribute makes sense.

-Brett


>
> > Just call it
> > "stdlib" or "stdlib_names".
>
> If you call it "stdlib", then you should make it a namedtuple that will
> expose various information, such as "sys.stdlib.module_names".
>


>
> Regards
>
> Antoine.
>
> _______________________________________________
> Python-Dev mailing list -- python-dev@python.org
> To unsubscribe send an email to python-dev-le...@python.org
> https://mail.python.org/mailman3/lists/python-dev.python.org/
> Message archived at
> https://mail.python.org/archives/list/python-dev@python.org/message/CJYWXVBIMDHRJCT4HZMOLJ7XMSVNZF6I/
> Code of Conduct: http://python.org/psf/codeofconduct/
>
_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/PI6IOOBUJ4DLW67VIJQILBXYXSI27X37/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to