Skip to content

Commit

Permalink
do not redirect stderr to /dev/null when submitting job
Browse files Browse the repository at this point in the history
Should fix skypilot-org#4199.
  • Loading branch information
cg505 committed Nov 1, 2024
1 parent bc51eae commit 3c4218f
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions sky/backends/cloud_vm_ray_backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -3278,9 +3278,12 @@ def _exec_code_on_head(
f'{cd} && {constants.SKY_RAY_CMD} job submit '
'--address=http://127.0.0.1:$RAY_DASHBOARD_PORT '
f'--submission-id {job_id}-$(whoami) --no-wait '
# Redirect stderr to /dev/null to avoid distracting error from ray.
f'"{constants.SKY_PYTHON_CMD} -u {script_path} > {remote_log_path} '
'2> /dev/null"')
# Do not use &>, which is not POSIX and may not work.
f'"{constants.SKY_PYTHON_CMD} -u {script_path} 2>&1 '
# Filter distracting error from ray.
'| grep --line-buffered -v https://github.com/ray-project/ray/issues/3644 '
f'> {remote_log_path}"'
)

code = job_lib.JobLibCodeGen.queue_job(job_id, job_submit_cmd)
job_submit_cmd = ' && '.join([mkdir_code, create_script_code, code])
Expand Down

0 comments on commit 3c4218f

Please sign in to comment.