diff --git a/moulin/fetchers/git.py b/moulin/fetchers/git.py index a878f4c..e885a85 100644 --- a/moulin/fetchers/git.py +++ b/moulin/fetchers/git.py @@ -69,13 +69,14 @@ def __init__(self, conf: YamlValue, build_dir: str, generator: ninja_syntax.Writ def gen_fetch(self): """Generate instruction to fetch git repo""" clone_target = self.git_dir - clone_stamp = create_stamp_name(self.build_dir, self.url, "clone") - checkout_stamp = create_stamp_name(self.build_dir, self.url, "checkout") + clone_stamp = create_stamp_name(self.build_dir, clone_target, self.url, "clone") + checkout_stamp = create_stamp_name(self.build_dir, clone_target, self.url, "checkout") if checkout_stamp in _SEEN_REPOS_REV: if self.git_rev != _SEEN_REPOS_REV[checkout_stamp]: # Fail on occurrence of different revision for the already downloaded repository - raise YAMLProcessingError(f"ERROR: Repository {self.url} has two revisions '{self.git_rev}' " + raise YAMLProcessingError(f"ERROR: Repository {self.url} cloned to '{clone_target}' " + f"has two revisions '{self.git_rev}' " f"and '{_SEEN_REPOS_REV[checkout_stamp]}'", self.conf["rev"].mark) else: # Do not checkout repos for the second time