Skip to content

Commit b27b971

Browse files
committed
Ray restored to cluster mode
1 parent b38cc9d commit b27b971

File tree

1 file changed

+4
-12
lines changed

1 file changed

+4
-12
lines changed

nixtla_tests/conftest.py

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
import pandas as pd
55
import pytest
66
import ray
7-
import sys
87
import utilsforecast.processing as ufp
98

109
from copy import deepcopy
@@ -655,17 +654,10 @@ def dask_future_ex_vars_df_diff_cols(distributed_future_ex_vars_df, renamer):
655654

656655
@pytest.fixture(scope="module")
657656
def ray_cluster_setup():
658-
if sys.platform.startswith('win'):
659-
# job could get stuck like
660-
# https://github.com/Nixtla/nixtla/actions/runs/15506996482/job/43663088378?pr=647
661-
# https://docs.ray.io/en/latest/ray-contribute/testing-tips.html#id3
662-
# On Windows, support for multi-node Ray clusters is currently experimental and untested
663-
ray.init(local_mode=True)
664-
else:
665-
ray_cluster = Cluster(initialize_head=True, head_node_args={"num_cpus": 2})
666-
ray.init(address=ray_cluster.address, ignore_reinit_error=True)
667-
# add mock node to simulate a cluster
668-
ray_cluster.add_node(num_cpus=2)
657+
ray_cluster = Cluster(initialize_head=True, head_node_args={"num_cpus": 2})
658+
ray.init(address=ray_cluster.address, ignore_reinit_error=True)
659+
# add mock node to simulate a cluster
660+
ray_cluster.add_node(num_cpus=2)
669661

670662
yield
671663
ray.shutdown()

0 commit comments

Comments
 (0)