2 new commits in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/cede7e36e826/ changeset: cede7e36e826 user: jmchilton date: 2013-03-01 06:56:56 summary: Update LWR client to pass along tool id and version, required if LWR server is configured to point to a toolbox. The LWR server uses this information to match the job up with a tool and uses the tool to validate inputs. For more information see: https://lwr.readthedocs.org/en/latest/#setting-up-a-public-lwr-server https://bitbucket.org/jmchilton/lwr/src/tip/test/validator_test.py Updates the LWR client to revision 8a249f4254eb6aa1eed8669f738c5a9764caccdb of the LWR. https://bitbucket.org/jmchilton/lwr/commits/8a249f4254eb6aa1eed8669f738c5a97... affected #: 2 files diff -r d1ab12313b6acfbfd51a38195d9c5e75716e7752 -r cede7e36e8261b2cd11f04db67dc92292412b74c lib/galaxy/jobs/runners/lwr.py --- a/lib/galaxy/jobs/runners/lwr.py +++ b/lib/galaxy/jobs/runners/lwr.py @@ -69,7 +69,8 @@ output_files = self.get_output_files(job_wrapper) input_files = job_wrapper.get_input_fnames() working_directory = job_wrapper.working_directory - file_stager = FileStager(client, command_line, job_wrapper.extra_filenames, input_files, output_files, job_wrapper.tool.tool_dir, working_directory) + tool = job_wrapper.tool + file_stager = FileStager(client, tool, command_line, job_wrapper.extra_filenames, input_files, output_files, working_directory) rebuilt_command_line = file_stager.get_rewritten_command_line() job_id = file_stager.job_id client.launch( rebuilt_command_line ) @@ -228,4 +229,4 @@ elif job.get_state() == model.Job.states.QUEUED: # LWR doesn't queue currently, so this indicates galaxy was shutoff while # job was being staged. Not sure how to recover from that. - job_state.job_wrapper.fail( "This job was killed when Galaxy was restarted. Please retry the job." ) \ No newline at end of file + job_state.job_wrapper.fail( "This job was killed when Galaxy was restarted. Please retry the job." ) diff -r d1ab12313b6acfbfd51a38195d9c5e75716e7752 -r cede7e36e8261b2cd11f04db67dc92292412b74c lib/galaxy/jobs/runners/lwr_client/__init__.py --- a/lib/galaxy/jobs/runners/lwr_client/__init__.py +++ b/lib/galaxy/jobs/runners/lwr_client/__init__.py @@ -132,7 +132,7 @@ """ - def __init__(self, client, command_line, config_files, input_files, output_files, tool_dir, working_directory): + def __init__(self, client, tool, command_line, config_files, input_files, output_files, working_directory): """ """ self.client = client @@ -140,7 +140,9 @@ self.config_files = config_files self.input_files = input_files self.output_files = output_files - self.tool_dir = os.path.abspath(tool_dir) + self.tool_id = tool.id + self.tool_version = tool.version + self.tool_dir = os.path.abspath(tool.tool_dir) self.working_directory = working_directory # Setup job inputs, these will need to be rewritten before @@ -161,7 +163,7 @@ self.__upload_rewritten_config_files() def __handle_setup(self): - job_config = self.client.setup() + job_config = self.client.setup(self.tool_id, self.tool_version) self.new_working_directory = job_config['working_directory'] self.new_outputs_directory = job_config['outputs_directory'] @@ -480,11 +482,16 @@ self.__raw_execute("clean", {"job_id": self.job_id}) @parseJson() - def setup(self): + def setup(self, tool_id=None, tool_version=None): """ Setup remote LWR server to run this job. """ - return self.__raw_execute("setup", {"job_id": self.job_id}) + setup_args = {"job_id": self.job_id} + if tool_id: + setup_args["tool_id"] = tool_id + if tool_version: + setup_args["tool_version"] = tool_version + return self.__raw_execute("setup", setup_args) def _read(path): https://bitbucket.org/galaxy/galaxy-central/commits/15eafd606d97/ changeset: 15eafd606d97 user: natefoo date: 2013-03-01 14:23:58 summary: Merged in jmchilton/galaxy-central-lwr (pull request #132) Updates required to target LWR servers configured to point to a toolbox. affected #: 2 files diff -r 3110de3062acd1eea7f57b717b434a44b0429447 -r 15eafd606d97f9700b5ec9bfc92bb8c50badd365 lib/galaxy/jobs/runners/lwr.py --- a/lib/galaxy/jobs/runners/lwr.py +++ b/lib/galaxy/jobs/runners/lwr.py @@ -69,7 +69,8 @@ output_files = self.get_output_files(job_wrapper) input_files = job_wrapper.get_input_fnames() working_directory = job_wrapper.working_directory - file_stager = FileStager(client, command_line, job_wrapper.extra_filenames, input_files, output_files, job_wrapper.tool.tool_dir, working_directory) + tool = job_wrapper.tool + file_stager = FileStager(client, tool, command_line, job_wrapper.extra_filenames, input_files, output_files, working_directory) rebuilt_command_line = file_stager.get_rewritten_command_line() job_id = file_stager.job_id client.launch( rebuilt_command_line ) @@ -228,4 +229,4 @@ elif job.get_state() == model.Job.states.QUEUED: # LWR doesn't queue currently, so this indicates galaxy was shutoff while # job was being staged. Not sure how to recover from that. - job_state.job_wrapper.fail( "This job was killed when Galaxy was restarted. Please retry the job." ) \ No newline at end of file + job_state.job_wrapper.fail( "This job was killed when Galaxy was restarted. Please retry the job." ) diff -r 3110de3062acd1eea7f57b717b434a44b0429447 -r 15eafd606d97f9700b5ec9bfc92bb8c50badd365 lib/galaxy/jobs/runners/lwr_client/__init__.py --- a/lib/galaxy/jobs/runners/lwr_client/__init__.py +++ b/lib/galaxy/jobs/runners/lwr_client/__init__.py @@ -132,7 +132,7 @@ """ - def __init__(self, client, command_line, config_files, input_files, output_files, tool_dir, working_directory): + def __init__(self, client, tool, command_line, config_files, input_files, output_files, working_directory): """ """ self.client = client @@ -140,7 +140,9 @@ self.config_files = config_files self.input_files = input_files self.output_files = output_files - self.tool_dir = os.path.abspath(tool_dir) + self.tool_id = tool.id + self.tool_version = tool.version + self.tool_dir = os.path.abspath(tool.tool_dir) self.working_directory = working_directory # Setup job inputs, these will need to be rewritten before @@ -161,7 +163,7 @@ self.__upload_rewritten_config_files() def __handle_setup(self): - job_config = self.client.setup() + job_config = self.client.setup(self.tool_id, self.tool_version) self.new_working_directory = job_config['working_directory'] self.new_outputs_directory = job_config['outputs_directory'] @@ -480,11 +482,16 @@ self.__raw_execute("clean", {"job_id": self.job_id}) @parseJson() - def setup(self): + def setup(self, tool_id=None, tool_version=None): """ Setup remote LWR server to run this job. """ - return self.__raw_execute("setup", {"job_id": self.job_id}) + setup_args = {"job_id": self.job_id} + if tool_id: + setup_args["tool_id"] = tool_id + if tool_version: + setup_args["tool_version"] = tool_version + return self.__raw_execute("setup", setup_args) def _read(path): 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.