From 05a5e2b1f0953d279569b3fa079756ba2c654e1e Mon Sep 17 00:00:00 2001 From: Haibo Lin Date: Wed, 22 Jul 2020 14:58:18 +0800 Subject: [PATCH] Make sure old_repo_dir for reusing exists Fixes: https://pagure.io/pungi/issue/1424 JIRA: RHELCMP-1519 Signed-off-by: Haibo Lin --- pungi/phases/pkgset/pkgsets.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pungi/phases/pkgset/pkgsets.py b/pungi/phases/pkgset/pkgsets.py index bd7e8764..e82a47cf 100644 --- a/pungi/phases/pkgset/pkgsets.py +++ b/pungi/phases/pkgset/pkgsets.py @@ -749,6 +749,9 @@ class KojiPackageSet(PackageSetBase): repo_dir = compose.paths.work.pkgset_repo(tag, create_dir=False) old_repo_dir = compose.paths.old_compose_path(repo_dir) + if not old_repo_dir: + self.log_debug("Can't find old repo dir to reuse.") + return False old_reuse_file = compose.paths.old_compose_path( compose.paths.work.pkgset_reuse_file(tag)