diff --git a/pungi/phases/gather/methods/method_hybrid.py b/pungi/phases/gather/methods/method_hybrid.py index 32fa85e8..4953635f 100644 --- a/pungi/phases/gather/methods/method_hybrid.py +++ b/pungi/phases/gather/methods/method_hybrid.py @@ -47,9 +47,15 @@ class FakePackage(object): @property def files(self): - return [ - os.path.join(dirname, basename) for (_, dirname, basename) in self.pkg.files - ] + paths = [] + # createrepo_c.Package.files is a tuple, but its length differs across + # versions. The constants define index at which the related value is + # located. + for entry in self.pkg.files: + paths.append( + os.path.join(entry[cr.FILE_ENTRY_PATH], entry[cr.FILE_ENTRY_NAME]) + ) + return paths @property def provides(self):