MCPcopy
hub / github.com/dask/dask / assert_eq

Function assert_eq

dask/dataframe/dask_expr/tests/_util.py:26–44  ·  view source on GitHub ↗
(a, b, *args, serialize_graph=True, **kwargs)

Source from the content-addressed store, hash-verified

24
25
26def assert_eq(a, b, *args, serialize_graph=True, **kwargs):
27 if serialize_graph:
28 # Check that no `Expr` instances are found in
29 # the graph generated by `Expr.dask`
30 with config.set({"dask-expr-no-serialize": True}):
31 for obj in [a, b]:
32 if hasattr(obj, "dask"):
33 try:
34 pickle.dumps(obj.dask)
35 except (AttributeError, pickle.PicklingError, TypeError):
36 try:
37 import cloudpickle as cp
38
39 cp.dumps(obj.dask)
40 except ImportError:
41 pass
42
43 # Use `dask.dataframe.assert_eq`
44 return dd_assert_eq(a, b, *args, **kwargs)

Callers 15

test_resample_apisFunction · 0.90
test_series_resampleFunction · 0.90
test_resample_aggFunction · 0.90
test_parquet_distributedFunction · 0.90
test_from_delayedFunction · 0.90
test_from_delayed_daskFunction · 0.90
test_disk_shuffleFunction · 0.90
test_task_shuffleFunction · 0.90

Calls 1

setMethod · 0.80

Tested by 15

test_resample_apisFunction · 0.72
test_series_resampleFunction · 0.72
test_resample_aggFunction · 0.72
test_parquet_distributedFunction · 0.72
test_from_delayedFunction · 0.72
test_from_delayed_daskFunction · 0.72
test_disk_shuffleFunction · 0.72
test_task_shuffleFunction · 0.72

Used in the wild real call sites across dependent graphs

searching dependent graphs…