diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 307a615f1f..194f1e64e3 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -4,7 +4,7 @@ on: branches: - main tags: - - '*' + - "*" pull_request: schedule: # Runs "At 00:01" (see https://crontab.guru) @@ -22,96 +22,8 @@ defaults: shell: bash -l {0} jobs: - software: - name: Setup - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - python-version: ["3.8", "3.9", "3.10"] - - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - - name: Set up environment - uses: conda-incubator/setup-miniconda@v2 - with: - miniforge-variant: Mambaforge - use-mamba: true - condarc-file: ci/condarc - python-version: ${{ matrix.python-version }} - environment-file: ci/environment.yml - - - name: Check upstream - run: | - if [[ ${{ github.event_name }} == "pull_request" ]] - then - REF="HEAD^2" - else - REF="HEAD" - fi - - COMMIT="$(git log -n 1 --pretty=format:%s $REF)" - if [[ "$COMMIT" == *"test-upstream"* || ${{ github.event_name }} == "schedule" ]] - then - TEST_UPSTREAM="true" - AB_BASELINE="coiled-upstream-py3.9 coiled-0.1.0-py3.9" - else - TEST_UPSTREAM="false" - AB_BASELINE="coiled-latest-py3.9 coiled-0.1.0-py3.9" - fi - - # Put TEST_UPSTREAM into $GITHUB_ENV so it can be used in subsequent workflow steps - echo $TEST_UPSTREAM - echo TEST_UPSTREAM=$TEST_UPSTREAM >> $GITHUB_ENV - - # Put env variables into files so it can be downloaded in subsequent workflow jobs - echo $TEST_UPSTREAM > test_upstream.txt - echo $AB_BASELINE > ab_baseline.txt - - - name: Build Coiled Software Environment - env: - DASK_COILED__TOKEN: ${{ secrets.COILED_BENCHMARK_BOT_TOKEN }} - run: | - PYTHON_VERSION_FORMATTED=$(echo "${{ matrix.python-version }}" | sed 's/\.//g' ) - NAME_HEAD=dask-engineering/coiled-runtime-${{ github.event_name }} - NAME_TAIL=$GITHUB_RUN_ID-py$PYTHON_VERSION_FORMATTED - if [[ ${{ github.event_name }} = 'pull_request' ]] - then - NAME_MID=${{ github.event.number }} - else - NAME_MID=$GITHUB_REF_TYPE-$(echo "$GITHUB_REF_NAME" | sed 's/\./-/g' ) - fi - # env name can only contain lowercase ASCII letters, numbers, hyphens and underscores - COILED_SOFTWARE_NAME=$NAME_HEAD-$(echo $NAME_MID-$NAME_TAIL | tr 'A-Z' 'a-z' | sed -r 's/[^a-z0-9_-]/_/g') - - # Create conda environment.yaml file for the latest software environment - python ci/create_latest_runtime_meta.py - ENV_FILE=coiled_software_environment.yaml - cat $ENV_FILE - - mamba install coiled - echo "Creating Coiled software environment for $COILED_SOFTWARE_NAME" - coiled env create --name $COILED_SOFTWARE_NAME --conda $ENV_FILE - - # Put COILED_SOFTWARE_NAME into a file so it can be downloaded in subsequent workflow jobs - echo $COILED_SOFTWARE_NAME > software_name.txt - - - name: Upload environment file - uses: actions/upload-artifact@v3 - with: - name: software-environment-py${{ matrix.python-version }} - path: | - coiled_software_environment.yaml - software_name.txt - test_upstream.txt - ab_baseline.txt - runtime: name: Runtime - ${{ matrix.os }}, Python ${{ matrix.python-version }}, Runtime ${{ matrix.runtime-version }} - needs: software runs-on: ${{ matrix.os }} timeout-minutes: 120 strategy: @@ -119,7 +31,7 @@ jobs: matrix: os: ["ubuntu-latest"] python-version: ["3.9"] - runtime-version: ["latest", "0.0.4", "0.1.0"] + runtime-version: ["upstream", "latest", "0.0.4", "0.1.0"] steps: - uses: actions/checkout@v2 @@ -135,16 +47,12 @@ jobs: python-version: ${{ matrix.python-version }} environment-file: ci/environment.yml - - name: Download software environment assets - if: matrix.runtime-version == 'latest' - uses: actions/download-artifact@v3 - with: - name: software-environment-py${{ matrix.python-version }} - - name: Install coiled-runtime env: COILED_RUNTIME_VERSION: ${{ matrix.runtime-version }} - run: source ci/scripts/install_coiled_runtime.sh + run: | + python ci/create_runtime_meta.py + source ci/scripts/install_coiled_runtime.sh - name: Run Coiled Runtime Tests id: test @@ -166,7 +74,6 @@ jobs: benchmarks: name: Benchmarks - ${{ matrix.os }}, Python ${{ matrix.python-version }}, Runtime ${{ matrix.runtime-version }} - needs: software runs-on: ${{ matrix.os }} timeout-minutes: 120 strategy: @@ -174,7 +81,7 @@ jobs: matrix: os: ["ubuntu-latest"] python-version: ["3.9"] - runtime-version: ["latest", "0.0.4", "0.1.0"] + runtime-version: ["upstream", "latest", "0.0.4", "0.1.0"] steps: - uses: actions/checkout@v2 @@ -190,16 +97,12 @@ jobs: python-version: ${{ matrix.python-version }} environment-file: ci/environment.yml - - name: Download software environment assets - if: matrix.runtime-version == 'latest' - uses: actions/download-artifact@v3 - with: - name: software-environment-py${{ matrix.python-version }} - - name: Install coiled-runtime env: COILED_RUNTIME_VERSION: ${{ matrix.runtime-version }} - run: source ci/scripts/install_coiled_runtime.sh + run: | + python ci/create_runtime_meta.py + source ci/scripts/install_coiled_runtime.sh - name: Run benchmarking tests id: benchmarking_tests @@ -221,7 +124,6 @@ jobs: stability: name: Stability - ${{ matrix.os }}, Python ${{ matrix.python-version }}, Runtime ${{ matrix.runtime-version }} - needs: software runs-on: ${{ matrix.os }} timeout-minutes: 120 strategy: @@ -229,7 +131,7 @@ jobs: matrix: os: ["ubuntu-latest"] python-version: ["3.8", "3.9", "3.10"] - runtime-version: ["latest", "0.0.4", "0.1.0"] + runtime-version: ["upstream", "latest", "0.0.4", "0.1.0"] include: - python-version: "3.9" runtime-version: "latest" @@ -252,16 +154,12 @@ jobs: python-version: ${{ matrix.python-version }} environment-file: ci/environment.yml - - name: Download software environment assets - if: matrix.runtime-version == 'latest' - uses: actions/download-artifact@v3 - with: - name: software-environment-py${{ matrix.python-version }} - - name: Install coiled-runtime env: COILED_RUNTIME_VERSION: ${{ matrix.runtime-version }} - run: source ci/scripts/install_coiled_runtime.sh + run: | + python ci/create_runtime_meta.py + source ci/scripts/install_coiled_runtime.sh - name: Run stability tests id: stability_tests @@ -282,39 +180,6 @@ jobs: name: stability-${{ matrix.os }}-${{ matrix.runtime-version }}-py${{ matrix.python-version }} path: stability-${{ matrix.os }}-${{ matrix.runtime-version }}-py${{ matrix.python-version }}.db - cleanup: - needs: [software, runtime, benchmarks, stability] - if: always() - name: Cleanup - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - python-version: ["3.8", "3.9", "3.10"] - steps: - - uses: actions/checkout@v2 - - - name: Set up Python - uses: actions/setup-python@v4 - with: - python-version: ${{ matrix.python-version }} - - - name: Install coiled - run: python -m pip install coiled - - - name: Download software environment assets - uses: actions/download-artifact@v3 - with: - name: software-environment-py${{ matrix.python-version }} - - - name: Remove Coiled software environment - env: - DASK_COILED__TOKEN: ${{ secrets.COILED_BENCHMARK_BOT_TOKEN }} - run: | - SOFTWARE_NAME=$(cat software_name.txt) - echo "Deleting $SOFTWARE_NAME" - coiled env delete $SOFTWARE_NAME - process-results: needs: [runtime, benchmarks, stability] name: Combine separate benchmark results @@ -341,7 +206,7 @@ jobs: env: AWS_ACCESS_KEY_ID: ${{ secrets.RUNTIME_CI_BOT_AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.RUNTIME_CI_BOT_AWS_SECRET_ACCESS_KEY }} - AWS_DEFAULT_REGION: us-east-2 # this is needed for boto for some reason + AWS_DEFAULT_REGION: us-east-2 # this is needed for boto for some reason DB_NAME: benchmark.db run: | aws s3 cp s3://coiled-runtime-ci/benchmarks/$DB_NAME . || true @@ -356,7 +221,7 @@ jobs: env: AWS_ACCESS_KEY_ID: ${{ secrets.RUNTIME_CI_BOT_AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.RUNTIME_CI_BOT_AWS_SECRET_ACCESS_KEY }} - AWS_DEFAULT_REGION: us-east-2 # this is needed for boto for some reason + AWS_DEFAULT_REGION: us-east-2 # this is needed for boto for some reason DB_NAME: benchmark.db run: | aws s3 cp $DB_NAME s3://coiled-runtime-ci/benchmarks/ @@ -364,7 +229,7 @@ jobs: - name: Upload benchmark results as artifact uses: actions/upload-artifact@v3 with: - name: benchmark.db + name: benchmark path: benchmark.db regressions: @@ -380,7 +245,7 @@ jobs: - uses: actions/download-artifact@v3 with: - name: benchmark.db + name: benchmark - name: Set up environment uses: conda-incubator/setup-miniconda@v2 @@ -451,7 +316,7 @@ jobs: - uses: actions/download-artifact@v3 with: - name: benchmark.db + name: benchmark - name: Set up environment uses: conda-incubator/setup-miniconda@v2 @@ -461,13 +326,8 @@ jobs: python-version: "3.9" environment-file: ci/environment-dashboard.yml - - name: Download software environment assets - uses: actions/download-artifact@v3 - with: - name: software-environment-py3.9 - - name: Generate dashboards - run: python dashboard.py -d benchmark.db -o static -b $(cat ab_baseline.txt) + run: python dashboard.py -d benchmark.db -o static -b coiled-latest-py3.9 coiled-upstream-py3.9 - name: Upload artifact uses: actions/upload-artifact@v3 diff --git a/README.md b/README.md index 84c5cc6779..100ca01131 100644 --- a/README.md +++ b/README.md @@ -57,10 +57,11 @@ The `coiled-runtime` test suite can be run locally with the following steps: the Coiled Dask Engineering AWS S3 account. 2. Create a Python environment and install development dependencies as specified in `ci/environment.yml`. -3. (Optional) If testing against an unreleased version of `coiled-runtime`, - create a Coiled software environment with the unreleased `coiled-runtime` installed - and set a local `COILED_SOFTWARE_NAME` environment variable to the name - of the software environment (e.g. `export COILED_SOFTWARE_NAME="account/software-name"`) +3. Install a coiled runtime environment. This might be from one of the environments + listed in ``environments/``, or it could be a development environment if you are + testing feature branches of dask or distributed. This test suite is configured + to run Coiled's ``package_sync`` feature, so your local environment should be copied + to the cluster. 4. Run tests with `python -m pytest tests` Additionally, tests are automatically run on pull requests to this repository. diff --git a/alembic/versions/2764a4f5582b_declare_bankruptcy_for_cluster_startup_.py b/alembic/versions/2764a4f5582b_declare_bankruptcy_for_cluster_startup_.py new file mode 100644 index 0000000000..1f3df6c7c5 --- /dev/null +++ b/alembic/versions/2764a4f5582b_declare_bankruptcy_for_cluster_startup_.py @@ -0,0 +1,30 @@ +"""Declare bankruptcy for cluster startup time + +Revision ID: 2764a4f5582b +Revises: 924e9b1430e1 +Create Date: 2022-09-14 11:45:46.024184 + +""" +from alembic import op +import sqlalchemy as sa + + +# revision identifiers, used by Alembic. +revision = "2764a4f5582b" +down_revision = "924e9b1430e1" +branch_labels = None +depends_on = None + + +def upgrade() -> None: + op.execute( + """ + delete from test_run + where originalname = 'test_default_cluster_spinup_time' + and path = 'benchmarks/test_coiled.py'; + """ + ) + + +def downgrade() -> None: + pass diff --git a/ci/create_latest_runtime_meta.py b/ci/create_runtime_meta.py similarity index 75% rename from ci/create_latest_runtime_meta.py rename to ci/create_runtime_meta.py index 4a7fa2680e..d9fbf7fe9c 100644 --- a/ci/create_latest_runtime_meta.py +++ b/ci/create_runtime_meta.py @@ -6,7 +6,6 @@ import shlex import subprocess import sys -from distutils.util import strtobool import yaml from jinja2 import Environment, FileSystemLoader, select_autoescape @@ -38,15 +37,20 @@ def main(): if package_name == "python": requirements[idx] = f"python =={python_version}" - # Optionally use the development version of `dask` and `distributed` - # from `dask/label/dev` conda channel - upstream = strtobool(os.environ.get("TEST_UPSTREAM", "false")) - if upstream: - upstream_packages = {"dask", "distributed"} - for idx, req in enumerate(requirements): - package_name = Requirement(req).name - if package_name in upstream_packages: - requirements[idx] = get_latest_conda_build(package_name) + if os.environ.get("COILED_RUNTIME_VERSION", "unknown") == "upstream": + requirements = [ + r + for r in requirements + if Requirement(r).name not in {"dask", "distributed"} + ] + requirements.append( + { + "pip": [ + "git+https://github.com/dask/dask@main", + "git+https://github.com/dask/distributed@main", + ] + } + ) # File compatible with `mamba env create --file <...>` env = { diff --git a/ci/scripts/combine-dbs.sh b/ci/scripts/combine-dbs.sh index 459fe2f86c..976e43ea42 100644 --- a/ci/scripts/combine-dbs.sh +++ b/ci/scripts/combine-dbs.sh @@ -16,6 +16,11 @@ DB_NAME=benchmark.tmp.db alembic upgrade head # Merge in the individual job dbs into our working copy for FILE in $(find benchmarks -name "*.db") do + # Skip the output DB if we see it + if [ ${FILE##*/} == $DB_NAME ]; then + echo "Skipping $FILE" + continue + fi echo "Processing $FILE" # Copy the individual table into the primary one. We make an intermediate # temp table so that we can null out the primary keys and reset the diff --git a/ci/scripts/install_coiled_runtime.sh b/ci/scripts/install_coiled_runtime.sh index a98a155bb4..a1044279cc 100644 --- a/ci/scripts/install_coiled_runtime.sh +++ b/ci/scripts/install_coiled_runtime.sh @@ -5,7 +5,7 @@ set -o errexit set -o nounset set -o xtrace -if [[ "$COILED_RUNTIME_VERSION" =~ latest|AB_ ]] +if [[ "$COILED_RUNTIME_VERSION" =~ upstream|latest|AB_ ]] then cat coiled_software_environment.yaml mamba env update --file coiled_software_environment.yaml @@ -15,4 +15,4 @@ fi # For debugging echo -e "--\n--Conda Environment (re-create this with \`conda env create --name -f \`)\n--" -mamba env export | grep -E -v '^prefix:.*$' \ No newline at end of file +mamba env export | grep -E -v '^prefix:.*$' diff --git a/ci/scripts/run_tests.sh b/ci/scripts/run_tests.sh index b6676e1887..6b3b53ecaf 100644 --- a/ci/scripts/run_tests.sh +++ b/ci/scripts/run_tests.sh @@ -5,19 +5,11 @@ set -o xtrace BENCHMARK="${BENCHMARK:-false}" # Ensure we run additional tests when testing the latest coiled-runtime -if [[ "$COILED_RUNTIME_VERSION" = 'latest' ]] +if [[ $COILED_RUNTIME_VERSION = 'latest' || $COILED_RUNTIME_VERSION = 'upstream' ]] then EXTRA_OPTIONS="--run-latest" - export COILED_SOFTWARE_NAME=$(cat software_name.txt) - export TEST_UPSTREAM=$(cat test_upstream.txt) -elif [[ "$COILED_RUNTIME_VERSION" =~ AB_ ]] -then - EXTRA_OPTIONS="" - export COILED_SOFTWARE_NAME=$(cat software_name.txt) - export TEST_UPSTREAM=$(cat test_upstream.txt) else EXTRA_OPTIONS="" - unset COILED_SOFTWARE_NAME fi if [[ $BENCHMARK = 'true' ]] then diff --git a/conftest.py b/conftest.py index c574252630..3611aa0005 100644 --- a/conftest.py +++ b/conftest.py @@ -65,8 +65,6 @@ def pytest_collection_modifyitems(config, items): def get_coiled_runtime_version(): - if strtobool(os.environ.get("TEST_UPSTREAM", "false")): - return "upstream" try: return os.environ["COILED_RUNTIME_VERSION"] except KeyError: @@ -78,37 +76,13 @@ def get_coiled_runtime_version(): if runtime_info: return runtime_info[0]["version"] else: - return "latest" + return "unknown" -def get_coiled_software_name(): - try: - return os.environ["COILED_SOFTWARE_NAME"] - except KeyError: - # Determine software environment from local `coiled-runtime` version (in installed) - out = subprocess.check_output( - shlex.split("conda list --json coiled-runtime"), text=True - ).rstrip() - runtime_info = json.loads(out) - if runtime_info: - version = runtime_info[0]["version"].replace(".", "-") - py_version = f"{sys.version_info[0]}{sys.version_info[1]}" - return f"coiled/coiled-runtime-{version}-py{py_version}" - else: - raise RuntimeError( - "Must either specific `COILED_SOFTWARE_NAME` environment variable " - "or have `coiled-runtime` installed" - ) - - -dask.config.set( - { - "coiled.account": "dask-engineering", - "coiled.software": get_coiled_software_name(), - } -) +dask.config.set({"coiled.account": "dask-engineering"}) COILED_RUNTIME_VERSION = get_coiled_runtime_version() +COILED_SOFTWARE_NAME = "package_sync" # ############################################### # @@ -213,7 +187,7 @@ def test_run_benchmark(benchmark_db_session, request, testrun_uid): dask_version=dask.__version__, distributed_version=distributed.__version__, coiled_runtime_version=COILED_RUNTIME_VERSION, - coiled_software_name=dask.config.get("coiled.software"), + coiled_software_name=COILED_SOFTWARE_NAME, python_version=".".join(map(str, sys.version_info)), platform=sys.platform, ci_run_url=WORKFLOW_URL, @@ -441,6 +415,7 @@ def small_cluster(request): worker_vm_types=["t3.large"], # 2CPU, 8GiB scheduler_vm_types=["t3.large"], backend_options=backend_options, + package_sync=True, ) as cluster: yield cluster diff --git a/tests/benchmarks/test_coiled.py b/tests/benchmarks/test_coiled.py index dc6b064229..bb39d95fa5 100644 --- a/tests/benchmarks/test_coiled.py +++ b/tests/benchmarks/test_coiled.py @@ -5,5 +5,7 @@ def test_default_cluster_spinup_time(request, auto_benchmark_time): - with Cluster(name=f"{request.node.originalname}-{uuid.uuid4().hex[:8]}"): + with Cluster( + name=f"{request.node.originalname}-{uuid.uuid4().hex[:8]}", package_sync=True + ): pass diff --git a/tests/benchmarks/test_parquet.py b/tests/benchmarks/test_parquet.py index 5e0d499371..feeaa7666b 100644 --- a/tests/benchmarks/test_parquet.py +++ b/tests/benchmarks/test_parquet.py @@ -21,6 +21,7 @@ def parquet_cluster(): n_workers=N_WORKERS, worker_vm_types=["m5.xlarge"], scheduler_vm_types=["m5.xlarge"], + package_sync=True, ) as cluster: yield cluster diff --git a/tests/runtime/test_build.py b/tests/runtime/test_build.py index 6c7b964af9..96ff838b26 100644 --- a/tests/runtime/test_build.py +++ b/tests/runtime/test_build.py @@ -7,10 +7,8 @@ import shlex import subprocess import sys -from distutils.util import strtobool import coiled -import dask import pytest import yaml from distributed import Client @@ -77,8 +75,10 @@ def test_install_dist(): # Test that versions of packages installed are consistent with those # specified in `meta.yaml` - if Version(dask.__version__).local or strtobool( - os.environ.get("TEST_UPSTREAM", "false") + if os.environ.get("COILED_RUNTIME_VERSION", "unknown") in ( + "upstream", + "latest", + "unknown", ): pytest.skip("Not valid on upstream build") diff --git a/tests/stability/test_deadlock.py b/tests/stability/test_deadlock.py index ff72db95ca..31c07b30a5 100644 --- a/tests/stability/test_deadlock.py +++ b/tests/stability/test_deadlock.py @@ -17,8 +17,10 @@ def test_repeated_merge_spill(upload_cluster_dump, benchmark_all): with Cluster( name=f"test_deadlock-{uuid.uuid4().hex}", n_workers=20, - worker_vm_types=["t3.medium"], + worker_vm_types=["t3.large"], + scheduler_vm_types=["t3.large"], wait_for_workers=True, + package_sync=True, ) as cluster: with Client(cluster) as client: with upload_cluster_dump(client, cluster), benchmark_all(client): diff --git a/tests/stability/test_spill.py b/tests/stability/test_spill.py index 45825a5f17..e7a10ba1a5 100644 --- a/tests/stability/test_spill.py +++ b/tests/stability/test_spill.py @@ -6,42 +6,15 @@ from dask.distributed import Client, wait -@pytest.mark.stability -@pytest.mark.parametrize("keep_around", (True, False)) -def test_spilling(keep_around, upload_cluster_dump, benchmark_all): +@pytest.fixture(scope="module") +def spill_cluster(): with Cluster( - name=f"test_spill-{uuid.uuid4().hex}", + f"spill-{uuid.uuid4().hex[:8]}", n_workers=5, - worker_disk_size=55, - worker_vm_types=["t3.medium"], - wait_for_workers=True, - environ={ - # Note: We set allowed-failures to ensure that no tasks are not retried - # upon ungraceful shutdown behavior during adaptive scaling - # but we receive a KilledWorker() instead. - "DASK_DISTRIBUTED__SCHEDULER__ALLOWED_FAILURES": "0" - }, - ) as cluster: - with Client(cluster) as client: - with upload_cluster_dump(client, cluster), benchmark_all(client): - arr = da.random.random((200, 2**27)).persist() # 200 GiB - wait(arr) - fut = client.compute(arr.sum()) - if not keep_around: - del arr - wait(fut) - - -@pytest.mark.skip( - reason="Skip until https://github.com/coiled/feedback/issues/185 is resolved." -) -@pytest.mark.stability -def test_tensordot_stress(upload_cluster_dump, benchmark_all): - with Cluster( - name=f"test_spill-{uuid.uuid4().hex}", - n_workers=5, - worker_disk_size=55, - worker_vm_types=["t3.medium"], + package_sync=True, + worker_disk_size=64, + worker_vm_types=["t3.large"], + scheduler_vm_types=["t3.large"], wait_for_workers=True, environ={ # Note: We set allowed-failures to ensure that no tasks are not retried @@ -55,10 +28,37 @@ def test_tensordot_stress(upload_cluster_dump, benchmark_all): "DASK_DISTRIBUTED__WORKER__CONNECTIONS__OUTGOING": "1", }, ) as cluster: - with Client(cluster) as client: - with upload_cluster_dump(client, cluster), benchmark_all(client): - a = da.random.random((48 * 1024, 48 * 1024)) # 18 GiB - b = (a @ a.T).sum().round(3) - fut = client.compute(b) - wait(fut) - assert fut.result() + yield cluster + + +@pytest.fixture +def spill_client(spill_cluster, upload_cluster_dump, benchmark_all): + with Client(spill_cluster) as client: + spill_cluster.scale(5) + client.wait_for_workers(5) + client.restart() + with upload_cluster_dump(client, spill_cluster), benchmark_all(client): + yield client + + +@pytest.mark.stability +@pytest.mark.parametrize("keep_around", (True, False)) +def test_spilling(spill_client, keep_around): + arr = da.random.random((64, 2**27)).persist() # 64 GiB, ~2x memory + wait(arr) + fut = spill_client.compute(arr.sum()) + if not keep_around: + del arr + wait(fut) + + +@pytest.mark.skip( + reason="Skip until https://github.com/coiled/feedback/issues/185 is resolved." +) +@pytest.mark.stability +def test_tensordot_stress(spill_client): + a = da.random.random((48 * 1024, 48 * 1024)) # 18 GiB + b = (a @ a.T).sum().round(3) + fut = spill_client.compute(b) + wait(fut) + assert fut.result()