commit/galaxy-central: kanwei: Tool versioning: now store version information in hda/ldda tables. Information is kept when copied between hda/ldda, and now displayed in the "Show Info" pages for hdas and lddas.
1 new changeset in galaxy-central: http://bitbucket.org/galaxy/galaxy-central/changeset/f3a18916bfd4/ changeset: f3a18916bfd4 user: kanwei date: 2011-08-24 06:45:31 summary: Tool versioning: now store version information in hda/ldda tables. Information is kept when copied between hda/ldda, and now displayed in the "Show Info" pages for hdas and lddas. affected #: 6 files (761 bytes) --- a/lib/galaxy/jobs/__init__.py Tue Aug 23 17:27:58 2011 -0400 +++ b/lib/galaxy/jobs/__init__.py Wed Aug 24 00:45:31 2011 -0400 @@ -534,7 +534,7 @@ if self.version_string_cmd: version_filename = self.get_version_string_path() if os.path.exists(version_filename): - self.version_string = "Tool version: %s" % open(version_filename).read() + self.version_string = open(version_filename).read() os.unlink(version_filename) if self.app.config.outputs_to_working_directory: @@ -587,7 +587,8 @@ dataset.blurb = 'done' dataset.peek = 'no peek' - dataset.info = context['stdout'] + context['stderr'] + self.version_string + dataset.info = context['stdout'] + context['stderr'] + dataset.tool_version = self.version_string dataset.set_size() if context['stderr']: dataset.blurb = "error" --- a/lib/galaxy/model/__init__.py Tue Aug 23 17:27:58 2011 -0400 +++ b/lib/galaxy/model/__init__.py Wed Aug 24 00:45:31 2011 -0400 @@ -753,7 +753,7 @@ """A base class for all 'dataset instances', HDAs, LDAs, etc""" states = Dataset.states permitted_actions = Dataset.permitted_actions - def __init__( self, id=None, hid=None, name=None, info=None, blurb=None, peek=None, extension=None, + def __init__( self, id=None, hid=None, name=None, info=None, blurb=None, peek=None, tool_version=None, extension=None, dbkey=None, metadata=None, history=None, dataset=None, deleted=False, designation=None, parent_id=None, validation_errors=None, visible=True, create_dataset=False, sa_session=None ): self.name = name or "Unnamed dataset" @@ -761,6 +761,7 @@ self.info = info self.blurb = blurb self.peek = peek + self.tool_version = tool_version self.extension = extension self.designation = designation self.metadata = metadata or dict() @@ -1020,6 +1021,7 @@ info=self.info, blurb=self.blurb, peek=self.peek, + tool_version=self.tool_version, extension=self.extension, dbkey=self.dbkey, dataset = self.dataset, @@ -1057,6 +1059,7 @@ info=self.info, blurb=self.blurb, peek=self.peek, + tool_version=self.tool_version, extension=self.extension, dbkey=self.dbkey, dataset=self.dataset, @@ -1410,6 +1413,7 @@ info=self.info, blurb=self.blurb, peek=self.peek, + tool_version=self.tool_version, extension=self.extension, dbkey=self.dbkey, dataset=self.dataset, @@ -1434,6 +1438,7 @@ info=self.info, blurb=self.blurb, peek=self.peek, + tool_version=self.tool_version, extension=self.extension, dbkey=self.dbkey, dataset=self.dataset, --- a/lib/galaxy/model/mapping.py Tue Aug 23 17:27:58 2011 -0400 +++ b/lib/galaxy/model/mapping.py Wed Aug 24 00:45:31 2011 -0400 @@ -113,6 +113,7 @@ Column( "info", TrimmedString( 255 ) ), Column( "blurb", TrimmedString( 255 ) ), Column( "peek" , TEXT ), + Column( "tool_version" , TEXT ), Column( "extension", TrimmedString( 64 ) ), Column( "metadata", MetadataType(), key="_metadata" ), Column( "parent_id", Integer, ForeignKey( "history_dataset_association.id" ), nullable=True ), @@ -305,6 +306,7 @@ Column( "info", TrimmedString( 255 ) ), Column( "blurb", TrimmedString( 255 ) ), Column( "peek" , TEXT ), + Column( "tool_version" , TEXT ), Column( "extension", TrimmedString( 64 ) ), Column( "metadata", MetadataType(), key="_metadata" ), Column( "parent_id", Integer, ForeignKey( "library_dataset_dataset_association.id" ), nullable=True ), --- a/templates/library/common/ldda_info.mako Tue Aug 23 17:27:58 2011 -0400 +++ b/templates/library/common/ldda_info.mako Wed Aug 24 00:45:31 2011 -0400 @@ -100,6 +100,13 @@ ${ldda.get_size( nice_size=True )} <div style="clear: both"></div></div> + %if ldda.tool_version: + <div class="form-row"> + <label>Tool version:</label> + ${ldda.tool_version} + <div style="clear: both"></div> + </div> + %endif <div class="form-row"><label>Data type:</label> ${ldda.ext} @@ -154,7 +161,7 @@ %endfor %if ldda.peek != "no peek": <div class="form-row"> - <div id="info${ldda.id}" class="historyItemBody"> + <div id="info${ldda.id}" class="historyItemBody"><label>Peek:</label><div><pre id="peek${ldda.id}" class="peek">${ldda.display_peek()}</pre></div></div> --- a/templates/show_params.mako Tue Aug 23 17:27:58 2011 -0400 +++ b/templates/show_params.mako Wed Aug 24 00:45:31 2011 -0400 @@ -49,6 +49,7 @@ <tr><td>Filesize:</td><td>${nice_size(hda.dataset.file_size)}</td></tr><tr><td>Dbkey:</td><td>${hda.dbkey}</td></tr><tr><td>Format:</td><td>${hda.ext}</td></tr> + <tr><td>Tool Version:</td><td>${hda.tool_version}</td></tr></table><br /><table class="tabletip"> 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.
participants (1)
-
Bitbucket