1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/861fd5d6c459/ Changeset: 861fd5d6c459 User: dannon Date: 2014-10-13 16:55:31+00:00 Summary: Fix Xslx binary (bad merge?). Affected #: 1 file diff -r be638dd2f087e895bb611a132999ec8309db0c03 -r 861fd5d6c459284aed91a2c92a01e5cd09064c18 lib/galaxy/datatypes/binary.py --- a/lib/galaxy/datatypes/binary.py +++ b/lib/galaxy/datatypes/binary.py @@ -281,22 +281,6 @@ return "Binary bam alignments file (%s)" % ( data.nice_size( dataset.get_size() ) ) -class Xlsx(Binary): - """Class for Excel 2007 (xlsx) files""" - file_ext="xlsx" - def sniff( self, filename ): - # Xlsx is compressed in zip format and must not be uncompressed in Galaxy. - try: - if zipfile.is_zipfile( filename ): - tempzip = zipfile.ZipFile( filename ) - if "[Content_Types].xml" in tempzip.namelist() and tempzip.read("[Content_Types].xml").find(b'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml') != -1: - return True - return False - except: - return False - -Binary.register_sniffable_binary_format("xlsx", "xlsx", Xlsx) - # ------------- Dataproviders # pipe through samtools view @@ -639,3 +623,19 @@ Binary.register_sniffable_binary_format("sqlite", "sqlite", SQlite) +class Xlsx(Binary): + """Class for Excel 2007 (xlsx) files""" + file_ext="xlsx" + def sniff( self, filename ): + # Xlsx is compressed in zip format and must not be uncompressed in Galaxy. + try: + if zipfile.is_zipfile( filename ): + tempzip = zipfile.ZipFile( filename ) + if "[Content_Types].xml" in tempzip.namelist() and tempzip.read("[Content_Types].xml").find(b'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml') != -1: + return True + return False + except: + return False + +Binary.register_sniffable_binary_format("xlsx", "xlsx", Xlsx) + Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.