Skip to content

Commit 26217e1

Browse files
committed
'exclude' should be able to override 'include' matches
Note that this behavior was different for files in dirs; see "if file.is_dir():" block a bit higher in the code. Related: python-poetry/poetry#1336
1 parent 275e5a4 commit 26217e1

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

poetry/core/masonry/builders/builder.py

+1-3
Original file line numberDiff line numberDiff line change
@@ -182,9 +182,7 @@ def find_files_to_add(
182182
path=file, project_root=self._path, source_root=source_root
183183
)
184184

185-
if self.is_excluded(
186-
file.relative_to(source_root)
187-
) and isinstance(include, PackageInclude):
185+
if self.is_excluded(file.relative_to(source_root)):
188186
continue
189187

190188
if file.suffix == ".pyc":

0 commit comments

Comments
 (0)