Skip to content

Commit

Permalink
Disallow passing node when on_this_cluster. (#946)
Browse files Browse the repository at this point in the history
  • Loading branch information
rohinb2 authored Jun 30, 2024
1 parent 1905cc6 commit 286a730
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions runhouse/resources/hardware/cluster.py
Original file line number Diff line number Diff line change
Expand Up @@ -1238,6 +1238,11 @@ def run(
"""
from runhouse.resources.envs import Env

if self.on_this_cluster() and node:
raise ValueError(
"Cannot specify a node when running from within the cluster."
)

if isinstance(commands, str):
commands = [commands]

Expand Down

0 comments on commit 286a730

Please sign in to comment.