From e2e6ef198bb281151b7fd0ab478d44b2066c8f55 Mon Sep 17 00:00:00 2001 From: Peiren Yang Date: Sun, 3 Mar 2019 22:46:07 +0100 Subject: [PATCH] [autoscaler] Make commands `bash -i` to support newer bash (#4181) The generated command in autoscaler/updater.py throws non-zero exit status 127 on Ubuntu 18.04. ## Related issue number Closes #4155, Closes #1444. --- python/ray/autoscaler/updater.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/python/ray/autoscaler/updater.py b/python/ray/autoscaler/updater.py index 17f4ad1c2..36aec9bf0 100644 --- a/python/ray/autoscaler/updater.py +++ b/python/ray/autoscaler/updater.py @@ -271,9 +271,10 @@ class NodeUpdater(object): ssh.append("-tt") if emulate_interactive: force_interactive = ( - "set -i || true && source ~/.bashrc && " + "true && source ~/.bashrc && " "export OMP_NUM_THREADS=1 PYTHONWARNINGS=ignore && ") - cmd = "bash --login -c {}".format(quote(force_interactive + cmd)) + cmd = "bash --login -c -i {}".format( + quote(force_interactive + cmd)) if port_forward is None: ssh_opt = []