diff --git a/.github/workflows/minimum-dependencies.yml b/.github/workflows/minimum-dependencies.yml new file mode 100644 index 00000000..7913238e --- /dev/null +++ b/.github/workflows/minimum-dependencies.yml @@ -0,0 +1,34 @@ +name: minimum-dependencies + +on: + push: + branches: ['main'] + paths-ignore: ['**.md', 'docs/**'] + pull_request: + paths-ignore: ['**.md', 'docs/**'] + workflow_dispatch: + +concurrency: + group: 'minimum-dependencies-${{ github.head_ref || github.run_id }}' + cancel-in-progress: true + +jobs: + run: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + lfs: true + - name: Setup Python + uses: actions/setup-python@v4 + with: + python-version: "3.9" + - name: Install + run: | + python3 -m pip install pip build wheel pytest -U + python3 -m pip install -e . -vv + - name: Run tests + run: | + python3 -m pytest diff --git a/pyproject.toml b/pyproject.toml index 5fadaabf..46a0d862 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,6 @@ Homepage = "https://github.com/dask-contrib/dask-awkward" [project.optional-dependencies] io = [ - "aiohttp;python_version<\"3.12\"", "pyarrow;python_version<\"3.12\"", ] complete = [ @@ -60,9 +59,9 @@ docs = [ "dask-sphinx-theme >=3.0.2", "sphinx-design", "sphinx-codeautolink", - "requests >=2.27.1", ] test = [ + "aiohttp;python_version<\"3.12\"", "dask-awkward[complete]", "dask-histogram", "distributed", @@ -70,7 +69,7 @@ test = [ "pandas", "pytest >=6.0", "pytest-cov >=3.0.0", - "requests >=2.27.1", + "requests", "uproot >=5.1.0rc1", ] diff --git a/tests/test_core.py b/tests/test_core.py index b6030409..b207e3f8 100644 --- a/tests/test_core.py +++ b/tests/test_core.py @@ -822,6 +822,7 @@ def test_map_partitions_no_dask_collections_passed(caa): @pytest.mark.parametrize("fn", [dak.count, dak.zeros_like, dak.ones_like]) def test_shape_only_ops(fn: Callable, tmp_path_factory: pytest.TempPathFactory) -> None: pytest.importorskip("pyarrow") + pytest.importorskip("pandas") a = ak.Array([{"a": 1, "b": 2}, {"a": 3, "b": 4}]) p = tmp_path_factory.mktemp("zeros-like-flat") ak.to_parquet(a, str(p / "file.parquet")) diff --git a/tests/test_io_text.py b/tests/test_io_text.py index 6bac855a..a96c2e70 100644 --- a/tests/test_io_text.py +++ b/tests/test_io_text.py @@ -8,9 +8,12 @@ import dask_awkward as dak from dask_awkward.lib.testutils import assert_eq +pytest.importorskip("pyarrow") +pytest.importorskip("requests") +pytest.importorskip("aiohttp") + def test_from_text() -> None: - pytest.importorskip("pyarrow") f1 = "https://raw.githubusercontent.com/dask-contrib/dask-awkward/main/README.md" f2 = "https://raw.githubusercontent.com/dask-contrib/dask-awkward/main/LICENSE" diff --git a/tests/test_parquet.py b/tests/test_parquet.py index 5eb1ee9b..f26cd2e9 100644 --- a/tests/test_parquet.py +++ b/tests/test_parquet.py @@ -5,6 +5,8 @@ import pytest pytest.importorskip("pyarrow") +pytest.importorskip("requests") +pytest.importorskip("aiohttp") import awkward as ak import fsspec