Skip to content

Commit 88f6690

Browse files
committed
Mark test_dask_classifier as XFAIL
1 parent 488f621 commit 88f6690

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

tests/test_distributed/test_gpu_with_dask/test_gpu_with_dask.py

+11-1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
import pytest
1111
from hypothesis import given, note, settings, strategies
1212
from hypothesis._settings import duration
13+
from packaging.version import parse as parse_version
1314

1415
import xgboost as xgb
1516
from xgboost import testing as tm
@@ -44,14 +45,20 @@
4445
try:
4546
import cudf
4647
import dask.dataframe as dd
48+
from dask import __version__ as dask_version
4749
from dask import array as da
4850
from dask.distributed import Client
4951
from dask_cuda import LocalCUDACluster
5052

5153
from xgboost import dask as dxgb
5254
from xgboost.testing.dask import check_init_estimation, check_uneven_nan
5355
except ImportError:
54-
pass
56+
dask_version = None
57+
58+
59+
dask_version_ge110 = dask_version and parse_version(dask_version) >= parse_version(
60+
"2024.11.0"
61+
)
5562

5663

5764
def run_with_dask_dataframe(DMatrixT: Type, client: Client) -> None:
@@ -375,6 +382,9 @@ def test_early_stopping(self, local_cuda_client: Client) -> None:
375382
dump = booster.get_dump(dump_format="json")
376383
assert len(dump) - booster.best_iteration == early_stopping_rounds + 1
377384

385+
@pytest.mark.xfail(
386+
dask_version_ge110, reason="Test cannot pass with Dask 2024.11.0+"
387+
)
378388
@pytest.mark.skipif(**tm.no_cudf())
379389
@pytest.mark.parametrize("model", ["boosting"])
380390
def test_dask_classifier(self, model: str, local_cuda_client: Client) -> None:

0 commit comments

Comments
 (0)