Skip to content

Commit b2e6331

Browse files
authored
fix: Check record equality before generating diff (#1123)
1. Less data generated 2. Allows to account for unordered map keys (foe CH, for example)
1 parent 4892773 commit b2e6331

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

plugin/diff.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ import (
99
)
1010

1111
func RecordDiff(l, r arrow.Record) string {
12+
if array.RecordApproxEqual(l, r, array.WithUnorderedMapKeys(true)) {
13+
return ""
14+
}
1215
var sb strings.Builder
1316
if l.NumCols() != r.NumCols() {
1417
return fmt.Sprintf("different number of columns: %d vs %d", l.NumCols(), r.NumCols())

0 commit comments

Comments
 (0)