mirror of
https://github.com/wassname/ray.git
synced 2026-07-23 13:10:11 +08:00
Start moving ray internal files to _private module (#10994)
This commit is contained in:
@@ -113,7 +113,8 @@ class TestSyncFunctionality(unittest.TestCase):
|
||||
}).trials
|
||||
|
||||
with patch.object(CommandBasedClient, "_execute") as mock_fn:
|
||||
with patch("ray.services.get_node_ip_address") as mock_sync:
|
||||
with patch(
|
||||
"ray._private.services.get_node_ip_address") as mock_sync:
|
||||
sync_config = tune.SyncConfig(
|
||||
sync_to_driver="echo {source} {target}")
|
||||
mock_sync.return_value = "0.0.0.0"
|
||||
@@ -209,7 +210,7 @@ class TestSyncFunctionality(unittest.TestCase):
|
||||
test_file_path = os.path.join(trial.logdir, "test.log2")
|
||||
self.assertFalse(os.path.exists(test_file_path))
|
||||
|
||||
with patch("ray.services.get_node_ip_address") as mock_sync:
|
||||
with patch("ray._private.services.get_node_ip_address") as mock_sync:
|
||||
mock_sync.return_value = "0.0.0.0"
|
||||
sync_config = tune.SyncConfig(sync_to_driver=sync_func_driver)
|
||||
[trial] = tune.run(
|
||||
|
||||
@@ -289,7 +289,7 @@ class Trainable:
|
||||
return ""
|
||||
|
||||
def get_current_ip(self):
|
||||
self._local_ip = ray.services.get_node_ip_address()
|
||||
self._local_ip = ray._private.services.get_node_ip_address()
|
||||
return self._local_ip
|
||||
|
||||
def train(self):
|
||||
|
||||
@@ -8,7 +8,7 @@ import traceback
|
||||
import types
|
||||
|
||||
import ray.cloudpickle as cloudpickle
|
||||
from ray.services import get_node_ip_address
|
||||
from ray._private.services import get_node_ip_address
|
||||
from ray.tune import TuneError
|
||||
from ray.tune.stopper import NoopStopper
|
||||
from ray.tune.progress_reporter import trial_progress_str
|
||||
|
||||
Reference in New Issue
Block a user