Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ci] [dask] test lightgbm.dask on macOS #6677

Merged
merged 8 commits into from
Mar 2, 2025
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
Next Next commit
[ci] [Dask] enable Dask tests on macOS
  • Loading branch information
jameslamb committed Oct 11, 2024
commit b6bdfdf57f3b28f392b26d12ec20a164d9b9e4af
3 changes: 3 additions & 0 deletions .vsts-ci.yml
Original file line number Diff line number Diff line change
@@ -243,6 +243,8 @@ jobs:
- script: |
git clean -d -f -x
displayName: 'Clean source directory'
# LGBM_SKIP_DASK_TESTS=true is set below only because running the tests under emulation is so slow...
# in theory, 'lightgbm.dask' should work without issue on aarch64 Linux systems
- script: |
cat > docker-script.sh <<EOF
export CONDA=\$HOME/miniforge
@@ -266,6 +268,7 @@ jobs:
--env OS_NAME=linux \
--env PRODUCES_ARTIFACTS=$PRODUCES_ARTIFACTS \
--env PYTHON_VERSION=$PYTHON_VERSION \
--env LGBM_SKIP_DASK_TESTS=true \
--env TASK=$TASK \
-v "$(Build.SourcesDirectory)":"$BUILD_DIRECTORY" \
-v "$(Build.ArtifactStagingDirectory)":"$(Build.ArtifactStagingDirectory)" \
2 changes: 1 addition & 1 deletion docs/Parallel-Learning-Guide.rst
Original file line number Diff line number Diff line change
@@ -64,7 +64,7 @@ LightGBM's Python-package supports distributed learning via `Dask`_. This integr

.. warning::

Dask integration is only tested on Linux.
Dask integration is only tested on macOS and Linux.

Dask Examples
'''''''''''''
11 changes: 6 additions & 5 deletions tests/python_package_test/test_dask.py
Original file line number Diff line number Diff line change
@@ -6,7 +6,6 @@
import socket
from itertools import groupby
from os import getenv
from platform import machine
from sys import platform
from urllib.parse import urlparse

@@ -17,10 +16,8 @@

from .utils import sklearn_multiclass_custom_objective

if not platform.startswith("linux"):
pytest.skip("lightgbm.dask is currently supported in Linux environments", allow_module_level=True)
if machine() != "x86_64":
pytest.skip("lightgbm.dask tests are currently skipped on some architectures like arm64", allow_module_level=True)
if platform in {"cygwin", "win3"}:
pytest.skip("lightgbm.dask is not currently supported on Windows", allow_module_level=True)
if not lgb.compat.DASK_INSTALLED:
pytest.skip("Dask is not installed", allow_module_level=True)

@@ -59,6 +56,10 @@
pytest.mark.skipif(getenv("TASK", "") == "mpi", reason="Fails to run with MPI interface"),
pytest.mark.skipif(getenv("TASK", "") == "gpu", reason="Fails to run with GPU interface"),
pytest.mark.skipif(getenv("TASK", "") == "cuda", reason="Fails to run with CUDA interface"),
pytest.mark.skipif(
getenv("LGBM_SKIP_DASK_TESTS", "") == "true",
reason="Skipping lightgbm.dask tests (found env variable LGBM_SKIP_DASK_TESTS=true)",
),
]


Loading
Oops, something went wrong.