[Git][reproducible-builds/diffoscope][master] Really avoid crashing if we unable to if we were unable to successfully...

Chris Lamb gitlab at salsa.debian.org
Fri Jan 25 23:33:18 CET 2019


Chris Lamb pushed to branch master at Reproducible Builds / diffoscope


Commits:
6b8e47dd by Chris Lamb at 2019-01-25T22:32:53Z
Really avoid crashing if we unable to if we were unable to successfully extract a "guestfs"-based file. (Re: #901982)

Gbp-Dch: ignore

- - - - -


1 changed file:

- diffoscope/comparators/fsimage.py


Changes:

=====================================
diffoscope/comparators/fsimage.py
=====================================
@@ -67,15 +67,14 @@ class FsImageContainer(Archive):
         self.g.close()
 
     def get_member_names(self):
+        if not guestfs:
+            return []
         return [os.path.basename(self.source.path) + '.tar']
 
     def extract(self, member_name, dest_dir):
         dest_path = os.path.join(dest_dir, member_name)
         logger.debug('filesystem image extracting to %s', dest_path)
-        try:
-            self.g.tar_out('/', dest_path)
-        except AttributeError as exc:
-            raise ContainerExtractionError(member_name, exc)
+        self.g.tar_out('/', dest_path)
         return dest_path
 
 



View it on GitLab: https://salsa.debian.org/reproducible-builds/diffoscope/commit/6b8e47ddf0a17dac3b7022a5f888f8409a8f560a

-- 
View it on GitLab: https://salsa.debian.org/reproducible-builds/diffoscope/commit/6b8e47ddf0a17dac3b7022a5f888f8409a8f560a
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.reproducible-builds.org/pipermail/rb-commits/attachments/20190125/231cf3ab/attachment.html>


More information about the rb-commits mailing list