diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2013-11-02 15:07:35 (GMT) |
---|---|---|
committer | Jason R. Coombs <jaraco@jaraco.com> | 2013-11-02 15:07:35 (GMT) |
commit | 3c0713550ec72fbba502466e84bd5271fd4e4cf3 (patch) | |
tree | 4f926080b3af61efed9ba9ee764daf8c42f2dc36 /Lib/distutils | |
parent | 83aafda57500bc84e5e7715e8766170509515eff (diff) | |
download | cpython-3c0713550ec72fbba502466e84bd5271fd4e4cf3.zip cpython-3c0713550ec72fbba502466e84bd5271fd4e4cf3.tar.gz cpython-3c0713550ec72fbba502466e84bd5271fd4e4cf3.tar.bz2 |
Issue #19286: [distutils] Only match files in build_py.find_data_files.
Diffstat (limited to 'Lib/distutils')
-rw-r--r-- | Lib/distutils/command/build_py.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/distutils/command/build_py.py b/Lib/distutils/command/build_py.py index 04c455f..c123c62 100644 --- a/Lib/distutils/command/build_py.py +++ b/Lib/distutils/command/build_py.py @@ -128,7 +128,8 @@ class build_py(Command): # Each pattern has to be converted to a platform-specific path filelist = glob(os.path.join(src_dir, convert_path(pattern))) # Files that match more than one pattern are only added once - files.extend([fn for fn in filelist if fn not in files]) + files.extend([fn for fn in filelist if fn not in files + and os.path.isfile(fn)]) return files def build_package_data(self): |