(proxy) add txz as valid download format

This commit is contained in:
Ad Schellevis 2016-01-27 13:56:41 +01:00
parent 2da105f078
commit c5299dba74

View File

@ -66,7 +66,8 @@ class ACLDownload(object):
"""
if self._source_data is not None:
# handle compressed data
if len(self._url) > 8 and self._url[-7:] == '.tar.gz':
if (len(self._url) > 8 and self._url[-7:] == '.tar.gz') \
or (len(self._url) > 4 and self._url[-4:] == '.txz'):
# source is in tar.gz format, extract all into a single string
try:
tf = tarfile.open(fileobj=StringIO.StringIO(self._source_data))