[Python-Dev] Re: glob's new include_hidden parameter

2022-09-12 Thread Mats Wichmann
On 9/12/22 19:48, Eryk Sun wrote: On 9/12/22, Mats Wichmann wrote: If `include_hidden` is true, the patterns '*', '?', '**' will match hidden directories. Shouldn't this explain what a "hidden directory" is? For example, a Windows user may think this means a directory with

[Python-Dev] Re: glob's new include_hidden parameter

2022-09-12 Thread Eryk Sun
On 9/12/22, Mats Wichmann wrote: > > If `include_hidden` is true, the patterns '*', '?', '**' will > match hidden directories. Shouldn't this explain what a "hidden directory" is? For example, a Windows user may think this means a directory with FILE_ATTRIBUTE_HIDDEN set, but that's not what's

[Python-Dev] Re: glob's new include_hidden parameter

2022-09-12 Thread Guido van Rossum
I think it's wrong in the docs. From looking at the code, that flag applies to all patterns, not just to `**`. (and "hidden" just means "begins with a dot") On Mon, Sep 12, 2022 at 9:04 AM Mats Wichmann wrote: > > Just spotted that 3.11 adds an include_hidden. At the moment a little > confused