Serhiy Storchaka <storchaka+cpyt...@gmail.com> added the comment:

Following Antoine's suggestion the patch now makes shutil.rmtree() using 
os.scandir() on all platforms.

I doubt about one thing. This patch changes os.listdir passed to the onerror 
handler to os.scandir. This can break a user code that checks if the first 
argument in onerror is os.listdir. If keep this change, it should be documented 
in the "Porting to 3.7" section. Alternatively, we can continue passing 
os.listdir if os.scandir() failed despites the fact that os.listdir no longer 
used.

----------
nosy: +pitrou

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue28564>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to