Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion trinity/utils/dlc_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ def get_dlc_env_vars() -> dict:

def is_running() -> bool:
"""Check if ray cluster is running."""
ret = subprocess.run("ray status", shell=True, capture_output=True)
python_dir = os.path.dirname(sys.executable)
ray_path = os.path.join(python_dir, "ray")
if os.path.exists(ray_path) is False:
ray_path = "ray"
ret = subprocess.run(f"{ray_path} status", shell=True, capture_output=True)
return ret.returncode == 0


Expand Down