On Thu, 2010-05-27 at 13:17 -0400, Seth Vidal wrote: > - # open it up as a file object so iterparse can cope with our gz > file > - if groupfile is not None and groupfile.endswith('.gz'): > - groupfile = gzip.open(groupfile) > + # open it up as a file object so iterparse can cope with our > compressed file > + if groupfile: > + groupfile = misc.decompress(groupfile)
When we have a non-compressed comps. this now raises Errors.MiscError ... yeh? I don't mind not raising and just returning the file, or changing the above somehow. In theory we will now "hide" problems where comps. comes in compressed as .xz etc. ... but I don't care :). > - local = local.replace('.bz2', '') > - misc.bunzipFile(dl_local, local) > + local = misc.decompress(dl_local) On the other side, this will fail is the decompression doesn't happen. Much less likely here, but probably means we need an arg. to switch. _______________________________________________ Yum-devel mailing list Yum-devel@lists.baseurl.org http://lists.baseurl.org/mailman/listinfo/yum-devel