Serhiy Storchaka added the comment:
May be slightly refactor the code?
def _select_from(self, parent_path, is_dir, exists, listdir):
try:
if not is_dir(parent_path):
return
yield from self._select_from2(parent_path, is_dir, exists, listdir)
except PermissionError:
return
def _select_from2(self, parent_path, is_dir, exists, listdir):
... # implementation
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue24120>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com