bpo-35652: shutil.copytree(copy_function=...) erroneously pass DirEntry instead of path str (GH-11997)

This commit is contained in:
Giampaolo Rodola 2019-02-26 12:04:41 +01:00 committed by GitHub
parent d5a551c269
commit c606a9cbd4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 21 additions and 1 deletions

View file

@ -472,7 +472,7 @@ def _copytree(entries, src, dst, symlinks, ignore, copy_function,
dirs_exist_ok=dirs_exist_ok)
else:
# Will raise a SpecialFileError for unsupported file types
copy_function(srcentry, dstname)
copy_function(srcobj, dstname)
# catch the Error from the recursive copytree so that we can
# continue with other files
except Error as err: