dask / dask/dask-ml

RuntimeError: Attempting to use an asynchronous Client in a synchronous context of `dask.compute`

Open
#1,016 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
951
Forks
262
PR merge metrics
No merged PRs in 30d

Description

**Describe the issue**:

When bumping `dask` to `2025.3.0`, almost all tests in those files
```
tests/model_selection/test_incremental.py
tests/model_selection/test_successive_halving.py
tests/model_selection/test_hyperband.py
```
sarted failing with:
```
RuntimeError: Attempting to use an asynchronous Client in a synchronous context of `dask.compute`
```

**Minimal Complete Verifiable Example**:

```console
$ pytest
```

**Anything else we need to know?**:

**Environment**:

- Dask version: 2025.3.0
- Python version: 3.12
- Operating System: NixOS
- Install method (conda, pip, source): nix

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.