Author max0x7ba
Recipients max0x7ba
Date 2021-06-10.15:53:42
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1623340423.37.0.118155398047.issue44380@roundup.psfhosted.org>
In-reply-to
Content
Problem:

`glob.glob` documentation states that "pathname ... can contain shell-style wildcards." 

However, it stops short of saying that shell-style wildcards are handled the same way as in a POSIX-compliant/friendly shell.

https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_13_02 POSIX requires that "`*` (asterisk) is a pattern that shall match any string, including the null string."

However, `glob.glob` pattern `*` (asterisk) doesn't match an empty/null string. 

Reproduction:

$ ls *.bash_profile
.bash_profile
$ python3 -c 'import glob; print(glob.glob("*.bash_profile"))'
[]
$ python3 -c 'import glob; print(glob.glob(".bash_profile"))'
['.bash_profile']
History
Date User Action Args
2021-06-10 15:53:43max0x7basetrecipients: + max0x7ba
2021-06-10 15:53:43max0x7basetmessageid: <1623340423.37.0.118155398047.issue44380@roundup.psfhosted.org>
2021-06-10 15:53:43max0x7balinkissue44380 messages
2021-06-10 15:53:42max0x7bacreate