mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Fix for history item html for taxonomy data type, eliminated the type from the registry-not quite ready for prime time. Fix for cleanup_datasets script.
This commit is contained in:
@@ -52,7 +52,6 @@ class Registry( object ):
|
||||
'qualityscore': qualityscore.QualityScore(),
|
||||
'scf' : images.Scf(),
|
||||
'tabular' : tabular.Tabular(),
|
||||
'taxonomy' : tabular.Taxonomy(),
|
||||
'txt' : data.Text(),
|
||||
'txtseq.zip' : images.Txtseq(),
|
||||
'wig' : interval.Wiggle()
|
||||
@@ -73,7 +72,6 @@ class Registry( object ):
|
||||
'qualityscore': 'text/plain',
|
||||
'scf' : 'application/octet-stream',
|
||||
'tabular' : 'text/plain',
|
||||
'taxonomy' : 'text/plani',
|
||||
'txt' : 'text/plain',
|
||||
'txtseq.zip' : 'application/zip',
|
||||
'wig' : 'text/plain'
|
||||
|
||||
@@ -155,17 +155,17 @@ class Taxonomy( Tabular ):
|
||||
continue
|
||||
|
||||
elems = line.split( '\t' )
|
||||
# This data type requires at least 24 columns in the data
|
||||
int_col_headers = len( elems ) - len( self.column_names )
|
||||
|
||||
if first: #generate header
|
||||
first = False
|
||||
out.append( '<tr>' )
|
||||
for index, elem in enumerate( elems[0:int_col_headers] ):
|
||||
out.append( "<th>%s</th>" % ( index+1 ) )
|
||||
for index, name in enumerate( self.column_names ):
|
||||
out.append( "<th>%s</th>" % name )
|
||||
out.append( '</tr>' )
|
||||
out.append( "<th>%s.%s</th>" % ( str( index+1 ), name ) )
|
||||
# This data type requires at least 24 columns in the data
|
||||
num_col_headers = len( elems ) - len( self.column_names )
|
||||
if num_col_headers > 0:
|
||||
for index in range( len( self.column_names ), len( elems ) ):
|
||||
out.append( "<th>%s</th>" % ( index+1 ) )
|
||||
out.append( '</tr>' )
|
||||
|
||||
while len( comments ) > 0:
|
||||
out.append( '<tr><td colspan="100%">' )
|
||||
|
||||
@@ -148,6 +148,7 @@ def purge_histories( h, cutoff_time, remove_from_disk ):
|
||||
start = time.clock()
|
||||
histories = h.query().filter( where ).options( eagerload( 'datasets' ) )
|
||||
for history in histories:
|
||||
errors = False
|
||||
for dataset in history.datasets:
|
||||
if not dataset.purged:
|
||||
file_size = dataset.file_size
|
||||
|
||||
Reference in New Issue
Block a user