Debian Codegraph @

debian/patches/disable-test_enforce_columns.patch

raw
1 Author: Diane Trout <[email protected]>
2 Description: The implementation of text_blocks_to_pandas in Dask 2024.2
3 uses dask_expr, and the test expects an exception to be raised.
4 We never packaged dask_expr so it's plausible the code behaves differently
5 than upstream expects without the package.
6 Later versions of dask include dask_expr so the conditional is removed.
7 Forwarded: no
8
9 --- a/dask/dataframe/io/tests/test_csv.py
10 +++ b/dask/dataframe/io/tests/test_csv.py
11 @@ -22,6 +22,7 @@
12 from dask.bytes.core import read_bytes
13 from dask.bytes.utils import compress
14 from dask.core import flatten
15 +import dask.dataframe as dd
16 from dask.dataframe._compat import PANDAS_GE_220, PANDAS_GE_300, tm
17 from dask.dataframe.io.csv import (
18 _infer_block_size,
19 @@ -44,6 +45,7 @@
20 # List of available compression format for test_read_csv_compression
21 compression_fmts = [fmt for fmt in compr] + [None]
22
23 +DASK_EXPR_ENABLED = dd._dask_expr_enabled()
24
25 def normalize_text(s):
26 return "\n".join(map(str.strip, s.strip().split("\n")))
27 @@ -342,6 +344,7 @@
28 assert all(df.dtypes.to_dict() == head.dtypes.to_dict() for df in dfs)
29
30
31 [email protected]("not DASK_EXPR_ENABLED")
32 @pytest.mark.parametrize(
33 "reader,blocks", [(pd.read_csv, csv_blocks), (pd.read_table, tsv_blocks)]
34 )