Fixes handling of leading dots.
Patch by Serhiy Storchaka.
dirname = os.curdir
try:
names = os.listdir(dirname)
- except os.error:
+ except OSError:
return []
- if pattern[0] != '.':
- names = [x for x in names if x[0] != '.']
+ if not _ishidden(pattern):
+ names = [x for x in names if not _ishidden(x)]
return fnmatch.filter(names, pattern)
def glob0(dirname, basename):
Library
-------
+ - Issue #16618: Make glob.glob match consistently across strings and bytes
+ regarding leading dots. Patch by Serhiy Storchaka.
+
+- Issue #16788: Add samestat to Lib/ntpath.py
+
- Issue #16702: test_urllib2_localnet tests now correctly ignores proxies for
localhost tests.