Skip to content

CuDF backend doesn't check CuDF version before doing version-dependent things #3335

@jpivarski

Description

@jpivarski

I had cudf 24.04.01 installed (apparently, when a package comes from another channel, update --all doesn't get it), and got this error from tests-cuda/test_3051_to_cuda.py:

>       return cudf.core.column.lists.ListColumn(
            size=length,
            data=None,
            mask=m,
            children=(ind_buf, cont),
            dtype=cudf.core.dtypes.ListDtype(cont.dtype),
        )
E       TypeError: ListColumn.__init__() got an unexpected keyword argument 'data'
E       
E       This error occurred while calling
E       
E           ak.to_cudf(
E               <Array [[[1, 2, 3], [], [3, 4]], []] type='2 * var * var * int64'>
E           )

Naturally, this is #3309. I updated cudf to 24.10.01 and there's no problem.

If you try to use this feature without CuDF, I'm sure you'd get some error message saying, "you need to install CuDF," but the above error message is mysterious if you don't know that you have an old version of CuDF. It would be more helpful if it said, "you need to install VERSION XYZ of CuDF," like

if parse_version(numba.__version__) < parse_version("0.50"):
raise ImportError(
"Awkward Array can only work with numba 0.50 or later "
f"(you have version {numba.__version__})"
)

@martindurant, is 24.10.00 the exact minimum? Which is the minimum CuDF version that is okay/the maximum CuDF version that is bad?

Metadata

Metadata

Assignees

No one assigned

    Labels

    gpuConcerns the GPU implementation (backend = "cuda')

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions