commit/galaxy-central: natefoo: Allow matching in tool_handlers and tool_runners on toolshed guid, toolshed guid minus version, and based (old) id. Matching occurs in that order (more specific IDs override less specific ones).
1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/changeset/75a97c971d36/ changeset: 75a97c971d36 user: natefoo date: 2012-12-05 23:50:23 summary: Allow matching in tool_handlers and tool_runners on toolshed guid, toolshed guid minus version, and based (old) id. Matching occurs in that order (more specific IDs override less specific ones). affected #: 1 file diff -r 42a6e3f82c0d2c5ec5bd4af1fca3bac125ffe9c9 -r 75a97c971d36599955f67384b6f36ca73a80dd2e lib/galaxy/tools/__init__.py --- a/lib/galaxy/tools/__init__.py +++ b/lib/galaxy/tools/__init__.py @@ -993,17 +993,24 @@ else: self.parallelism = None # Set job handler(s). Each handler is a dict with 'url' and, optionally, 'params'. - self_id = self.id.lower() + self_ids = [ self.id.lower() ] + if self.old_id != self.id: + # Handle toolshed guids + self_ids = [ self.id.lower(), self.id.lower().rsplit('/',1)[0], self.old_id.lower() ] self.job_handlers = [ { "name" : name } for name in self.app.config.default_job_handlers ] # Set custom handler(s) if they're defined. - if self_id in self.app.config.tool_handlers: - self.job_handlers = self.app.config.tool_handlers[ self_id ] + for self_id in self_ids: + if self_id in self.app.config.tool_handlers: + self.job_handlers = self.app.config.tool_handlers[ self_id ] + break # Set job runner(s). Each runner is a dict with 'url' and, optionally, 'params'. # Set job runner to the cluster default self.job_runners = [ { "url" : self.app.config.default_cluster_job_runner } ] # Set custom runner(s) if they're defined. - if self_id in self.app.config.tool_runners: - self.job_runners = self.app.config.tool_runners[ self_id ] + for self_id in self_ids: + if self_id in self.app.config.tool_runners: + self.job_runners = self.app.config.tool_runners[ self_id ] + break # Is this a 'hidden' tool (hidden in tool menu) self.hidden = util.xml_text(root, "hidden") if self.hidden: self.hidden = util.string_as_bool(self.hidden) 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