1 new changeset in galaxy-central: http://bitbucket.org/galaxy/galaxy-central/changeset/a86e1fa82a89/ changeset: r5082:a86e1fa82a89 user: kanwei date: 2011-02-17 21:35:07 summary: Add a "format_source" attribute to the ToolConfig output data element [JJ Johnson]. Closes #470 affected #: 2 files (426 bytes) --- a/lib/galaxy/tools/__init__.py Thu Feb 17 14:48:53 2011 -0500 +++ b/lib/galaxy/tools/__init__.py Thu Feb 17 15:35:07 2011 -0500 @@ -249,10 +249,11 @@ (format, metadata_source, parent) """ - def __init__( self, name, format=None, metadata_source=None, + def __init__( self, name, format=None, format_source=None, metadata_source=None, parent=None, label=None, filters = None, actions = None ): self.name = name self.format = format + self.format_source = format_source self.metadata_source = metadata_source self.parent = parent self.label = label @@ -559,6 +560,7 @@ output = ToolOutput( data_elem.get("name") ) output.format = data_elem.get("format", "data") output.change_format = data_elem.findall("change_format") + output.format_source = data_elem.get("format_source", None) output.metadata_source = data_elem.get("metadata_source", "") output.parent = data_elem.get("parent", None) output.label = util.xml_text( data_elem, "label" ) --- a/lib/galaxy/tools/actions/__init__.py Thu Feb 17 14:48:53 2011 -0500 +++ b/lib/galaxy/tools/actions/__init__.py Thu Feb 17 15:35:07 2011 -0500 @@ -244,6 +244,12 @@ ext = output.format if ext == "input": ext = input_ext + if output.format_source is not None and output.format_source in inp_data: + try: + ext = inp_data[output.format_source].ext + except Exception, e: + pass + #process change_format tags if output.change_format: if params is None: 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.