From 3af55c08f4563b4404c509abf5402e30c9c58bda Mon Sep 17 00:00:00 2001 From: Ondřej Nosek Date: Aug 24 2020 23:27:35 +0000 Subject: Skip 'sources' file when it is missing JIRA: RHELCMP-1968 Resolves: rhbz#1867440 Resolves: rhbz#1869848 Signed-off-by: Ondřej Nosek --- diff --git a/pyrpkg/layout/layouts.py b/pyrpkg/layout/layouts.py index 7324708..fe91b8c 100644 --- a/pyrpkg/layout/layouts.py +++ b/pyrpkg/layout/layouts.py @@ -42,8 +42,7 @@ class DistGitLayout(BaseLayout): if len([f for f in os.listdir(path) if f.endswith('.spec')]) == 0: raise LayoutError('spec file not found.') - sources = 'sources' if os.path.exists('%s/sources' % path) else None - return cls(root_dir=path, sources_file_template=sources) + return cls(root_dir=path) class SRPMLayout(BaseLayout):