From d5c5d8902b3d6ef13494af7fb727a40b6b9ecef2 Mon Sep 17 00:00:00 2001 From: Lonnie Liu Date: Fri, 26 Jan 2024 01:28:54 +0000 Subject: [PATCH] [data] fix failing huggingface test Signed-off-by: Lonnie Liu --- python/ray/data/tests/test_huggingface.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/python/ray/data/tests/test_huggingface.py b/python/ray/data/tests/test_huggingface.py index e8ef389a6be1..a94ce6349a3f 100644 --- a/python/ray/data/tests/test_huggingface.py +++ b/python/ray/data/tests/test_huggingface.py @@ -1,5 +1,7 @@ import datasets +import pyarrow import pytest +from packaging.version import Version import ray from ray.tests.conftest import * # noqa @@ -45,6 +47,10 @@ def test_huggingface(ray_start_regular_shared): datasets.Version(datasets.__version__) < datasets.Version("2.8.0"), reason="IterableDataset.iter() added in 2.8.0", ) +@pytest.mark.skipif( + Version(pyarrow.__version__) < Version("8.0.0"), + reason="pyarrow.Table.to_reader() added in 8.0.0", +) # Note, pandas is excluded here because IterableDatasets do not support pandas format. @pytest.mark.parametrize( "batch_format",