STINNER Victor added the comment: Context manager protocol, close() method: it looks more and more like a file. In this case, I suggest to emit a ResourceWarning in the destructor if it's not closed explicitly. It mean that the scandir() must always be used with "with" or at least that close() is always closed.
We probably need to update the code to be more explicitly on that. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue25994> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com