diff --git a/python/cudf/cudf/core/dataframe.py b/python/cudf/cudf/core/dataframe.py index 1dddcb9e3af..a444d87b50c 100644 --- a/python/cudf/cudf/core/dataframe.py +++ b/python/cudf/cudf/core/dataframe.py @@ -6519,7 +6519,7 @@ def _get_union_of_series_names(series_list): else: names_list.append(series.name) if unnamed_count == len(series_list): - names_list = [*range(len(series_list))] + names_list = range(len(series_list)) return names_list diff --git a/python/cudf/cudf/tests/test_dataframe.py b/python/cudf/cudf/tests/test_dataframe.py index 61c3f428019..3e359335719 100644 --- a/python/cudf/cudf/tests/test_dataframe.py +++ b/python/cudf/cudf/tests/test_dataframe.py @@ -7665,9 +7665,14 @@ def test_dataframe_init_from_series_list(data, ignore_dtype, columns): actual = cudf.DataFrame(gd_data, columns=columns) if ignore_dtype: - assert_eq(expected.fillna(-1), actual.fillna(-1), check_dtype=False) + assert_eq( + expected.fillna(-1), + actual.fillna(-1), + check_dtype=False, + check_index_type=True, + ) else: - assert_eq(expected, actual) + assert_eq(expected, actual, check_index_type=True) @pytest.mark.parametrize( diff --git a/python/dask_cudf/dask_cudf/tests/test_groupby.py b/python/dask_cudf/dask_cudf/tests/test_groupby.py index fce9b773dac..274c6670426 100644 --- a/python/dask_cudf/dask_cudf/tests/test_groupby.py +++ b/python/dask_cudf/dask_cudf/tests/test_groupby.py @@ -17,6 +17,7 @@ @pytest.mark.parametrize("aggregation", SUPPORTED_AGGS) @pytest.mark.parametrize("series", [False, True]) def test_groupby_basic(series, aggregation): + np.random.seed(0) pdf = pd.DataFrame( { "x": np.random.randint(0, 5, size=10000),