1 new changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/c265358e1062/
changeset: c265358e1062
user: jgoecks
date: 2011-10-01 00:38:30
summary: Fix problems with computing indices for GFF/GTF datasets.
affected #: 1 file (-1 bytes)
--- a/lib/galaxy/datatypes/util/gff_util.py Fri Sep 30 15:07:11 2011 -0400
+++ b/lib/galaxy/datatypes/util/gff_util.py Fri Sep 30 18:38:30 2011 -0400
@@ -133,6 +133,7 @@
self.last_line = None
self.cur_offset = 0
self.seed_interval = None
+ self.seed_interval_line_len = 0
def parse_row( self, line ):
interval = GFFInterval( self, line.split( "\t" ), self.chrom_col, self.feature_col, \
@@ -160,12 +161,12 @@
# For debugging, uncomment this to propogate parsing exceptions up.
# I.e. the underlying reason for an unexpected StopIteration exception
# can be found by uncommenting this.
- #raise e
+ # raise e
#
# Get next GFFFeature
#
- raw_size = 0
+ raw_size = self.seed_interval_line_len
# If there is no seed interval, set one. Also, if there are no more
# intervals to read, this is where iterator dies.
@@ -184,8 +185,9 @@
return_val = self.seed_interval
return_val.raw_size = len( self.current_line )
self.seed_interval = None
+ self.seed_interval_line_len = 0
return return_val
-
+
# Initialize feature identifier from seed.
feature_group = self.seed_interval.attributes.get( 'group', None ) # For GFF
# For GFF3
@@ -220,21 +222,28 @@
if isinstance( interval, Comment ):
continue
- # If interval not associated with feature, break.
+ # Determine if interval is part of feature.
+ part_of = True
group = interval.attributes.get( 'group', None )
# GFF test:
if group and feature_group != group:
- break
+ part_of = False
# GFF3 test:
parent_id = interval.attributes.get( 'Parent', None )
cur_id = interval.attributes.get( 'ID', None )
if ( cur_id and cur_id != feature_id ) or ( parent_id and parent_id != feature_id ):
- break
+ part_of = False
# GTF test:
gene_id = interval.attributes.get( 'gene_id', None )
transcript_id = interval.attributes.get( 'transcript_id', None )
if ( transcript_id and transcript_id != feature_transcript_id ) or \
( gene_id and gene_id != feature_gene_id ):
+ part_of = False
+
+ # If interval is not part of feature, clean up and break.
+ if not part_of:
+ # Adjust raw size because current line is not part of feature.
+ raw_size -= len( self.current_line )
break
# Interval associated with feature.
@@ -242,6 +251,7 @@
# Last interval read is the seed for the next interval.
self.seed_interval = interval
+ self.seed_interval_line_len = len( self.current_line )
# Return feature.
feature = GFFFeature( self, self.chrom_col, self.feature_col, self.start_col, \
@@ -255,7 +265,6 @@
return feature
-
def convert_bed_coords_to_gff( interval ):
"""
Converts an interval object's coordinates from BED format to GFF format.
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.
1 new changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/c32929b315bd/
changeset: c32929b315bd
user: natefoo
date: 2011-09-30 21:07:11
summary: Fix for a minor bug in e28ebc25b2e7
affected #: 1 file (-1 bytes)
--- a/lib/galaxy/web/controllers/dataset.py Fri Sep 30 14:21:51 2011 -0400
+++ b/lib/galaxy/web/controllers/dataset.py Fri Sep 30 15:07:11 2011 -0400
@@ -690,7 +690,7 @@
# If data is binary or an image, stream without template; otherwise, use display template.
# TODO: figure out a way to display images in display template.
if isinstance(dataset.datatype, datatypes.binary.Binary) or isinstance(dataset.datatype, datatypes.images.Image) or isinstance(dataset.datatype, datatypes.images.Html):
- trans.response.set_content_type( data.get_mime() )
+ trans.response.set_content_type( dataset.get_mime() )
return open( dataset.file_name )
else:
# Get rating data.
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.
1 new changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/418f75a6041a/
changeset: 418f75a6041a
user: greg
date: 2011-09-30 16:50:02
summary: Fix for retrieving the list of cloned tool shed repositories from a local Galaxy instance.
affected #: 1 file (-1 bytes)
--- a/lib/galaxy/web/base/controller.py Fri Sep 30 09:48:56 2011 -0400
+++ b/lib/galaxy/web/base/controller.py Fri Sep 30 10:50:02 2011 -0400
@@ -1304,7 +1304,8 @@
status = params.get( 'status', 'done' )
if webapp == 'galaxy':
cloned_repositories = trans.sa_session.query( trans.model.ToolShedRepository ) \
- .filter( trans.model.ToolShedRepository.deleted == False )
+ .filter( trans.model.ToolShedRepository.deleted == False ) \
+ .all()
return trans.fill_template( '/webapps/galaxy/admin/index.mako',
webapp=webapp,
cloned_repositories=cloned_repositories,
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.
1 new changeset in galaxy-central:
http://bitbucket.org/galaxy/galaxy-central/changeset/338ead4737ba/
changeset: 338ead4737ba
user: natefoo
date: 2011-09-29 22:45:19
summary: Don't include purged histories in usage calculation.
affected #: 1 file (-1 bytes)
--- a/lib/galaxy/model/__init__.py Wed Sep 28 15:41:21 2011 -0400
+++ b/lib/galaxy/model/__init__.py Thu Sep 29 16:45:19 2011 -0400
@@ -90,7 +90,7 @@
total = 0
# this can be a huge number and can run out of memory, so we avoid the mappers
db_session = object_session( self )
- for history in db_session.query( History ).enable_eagerloads( False ).filter_by( user_id=self.id ).yield_per( 1000 ):
+ for history in db_session.query( History ).enable_eagerloads( False ).filter_by( user_id=self.id, purged=False ).yield_per( 1000 ):
for hda in db_session.query( HistoryDatasetAssociation ).enable_eagerloads( False ).filter_by( history_id=history.id, purged=False ).yield_per( 1000 ):
if not hda.dataset.id in dataset_ids and not hda.dataset.purged and not hda.dataset.library_associations:
dataset_ids.append( hda.dataset.id )
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.