diff --git a/prefect_gcp/workers/cloud_run_v2.py b/prefect_gcp/workers/cloud_run_v2.py index 1501c37..6237bed 100644 --- a/prefect_gcp/workers/cloud_run_v2.py +++ b/prefect_gcp/workers/cloud_run_v2.py @@ -214,13 +214,13 @@ def _populate_or_format_command(self): command = self.job_body["template"]["template"]["containers"][0].get("command") if command is None: - self.job_body["template"]["template"]["containers"][0]["command"] = ( - shlex.split(self._base_flow_run_command()) - ) + self.job_body["template"]["template"]["containers"][0][ + "command" + ] = shlex.split(self._base_flow_run_command()) elif isinstance(command, str): - self.job_body["template"]["template"]["containers"][0]["command"] = ( - shlex.split(command) - ) + self.job_body["template"]["template"]["containers"][0][ + "command" + ] = shlex.split(command) def _format_args_if_present(self): """ @@ -229,9 +229,9 @@ def _format_args_if_present(self): args = self.job_body["template"]["template"]["containers"][0].get("args") if args is not None and isinstance(args, str): - self.job_body["template"]["template"]["containers"][0]["args"] = ( - shlex.split(args) - ) + self.job_body["template"]["template"]["containers"][0][ + "args" + ] = shlex.split(args) # noinspection PyMethodParameters @validator("job_body")