Skip to content

tests/comparators/test_fsimage.py::test_differences_fat failing in ubuntu-devel

tests/comparators/test_fsimage.py::test_differences_fat is failing in ubuntu-devel, see job #974092.

==================================== ERRORS ====================================
____________________ ERROR at setup of test_differences_fat ____________________
img1_fat12 = <<class 'abc.FsImageFile'> /builds/reproducible-builds/diffoscope/tests/data/test1.fat12>
img2_fat12 = <<class 'abc.FsImageFile'> /builds/reproducible-builds/diffoscope/tests/data/test2.fat12>
guestfs_tempdir = '/tmp/tmpc3z7yn4p_diffoscope'
    @pytest.fixture
    def differences_fat(img1_fat12, img2_fat12, guestfs_tempdir):
>       return img1_fat12.compare(img2_fat12).details
guestfs_tempdir = '/tmp/tmpc3z7yn4p_diffoscope'
img1_fat12 = <<class 'abc.FsImageFile'> /builds/reproducible-builds/diffoscope/tests/data/test1.fat12>
img2_fat12 = <<class 'abc.FsImageFile'> /builds/reproducible-builds/diffoscope/tests/data/test2.fat12>
tests/comparators/test_fsimage.py:120: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
diffoscope/comparators/utils/file.py:472: in compare
    difference = self._compare_using_details(other, source)
diffoscope/comparators/utils/file.py:418: in _compare_using_details
    details.extend(
diffoscope/comparators/utils/container.py:132: in comparisons
    other_members = OrderedDict(other.get_adjusted_members_sizes())
diffoscope/comparators/utils/container.py:127: in get_adjusted_members_sizes
    size = path_apparent_size(member.path)
diffoscope/comparators/utils/archive.py:98: in path
    self._path = self.container.extract(
diffoscope/comparators/fsimage.py:89: in extract
    self.g.tar_out("/", dest_path)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
self = <guestfs.GuestFS object at 0x7f89236fe550>, directory = '/'
tarfile = '/tmp/diffoscope_7sl_d5j4/tmpwyz98re4/test2.fat12.tar'
compress = None, numericowner = None, excludes = None, xattrs = None
selinux = None, acls = None
    def tar_out(self, directory, tarfile, compress=None, numericowner=None,
                excludes=None, xattrs=None, selinux=None, acls=None):
        """This command packs the contents of directory and
        downloads it to local file "tarfile".
    
        The optional "compress" flag controls compression. If
        not given, then the output will be an uncompressed tar
        file. Otherwise one of the following strings may be
        given to select the compression type of the output file:
        "compress", "gzip", "bzip2", "xz", "lzop". (Note that
        not all builds of libguestfs will support all of these
        compression types).
    
        The other optional arguments are:
    
        "excludes"
        A list of wildcards. Files are excluded if they
        match any of the wildcards.
    
        "numericowner"
        If set to true, the output tar file will contain
        UID/GID numbers instead of user/group names.
    
        "xattrs"
        If set to true, extended attributes are saved in the
        output tar.
    
        "selinux"
        If set to true, SELinux contexts are saved in the
        output tar.
    
        "acls"
        If set to true, POSIX ACLs are saved in the output
        tar.
        """
        self._check_not_closed()
>       r = libguestfsmod.tar_out(self._o, directory, tarfile, compress,
                                  numericowner, excludes, xattrs, selinux,
                                  acls)
E       RuntimeError: tar_out: call launch before using this function
E       (in guestfish, don't forget to use the 'run' command)
acls       = None
compress   = None
directory  = '/'
excludes   = None
numericowner = None
self       = <guestfs.GuestFS object at 0x7f89236fe550>
selinux    = None
tarfile    = '/tmp/diffoscope_7sl_d5j4/tmpwyz98re4/test2.fat12.tar'
xattrs     = None
/usr/lib/python3/dist-packages/guestfs.py:10307: RuntimeError
------------------------------ Captured log setup ------------------------------

Not sure what is going on, as we do very much call launch, and we could only get to this code if we could start guestfs and list the filesystems, etc.

I don't have an Ubuntu system handy to debug, so help welcome.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information