Skip to content

Commit

Permalink
Updated hashdiff_tables.py to add more logging
Browse files Browse the repository at this point in the history
  • Loading branch information
ChaosHour committed Feb 6, 2025
1 parent 2019c34 commit 43b78af
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions data_diff/hashdiff_tables.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ def _bisect_and_diff_segments(
# NEW: If segment_range_diff flag is True, skip downloading rows and diffing.
if self.segment_range_diff:
logger.info(". " * level + "Skipping row download and diff due to segment_range_diff flag.")
return []
return

if self.bisection_disabled or max_rows < self.bisection_threshold or max_space_size < self.bisection_factor * 2:
rows1, rows2 = self._threaded_call("get_values", [table1, table2])
Expand Down Expand Up @@ -265,9 +265,6 @@ def _bisect_and_diff_segments(
self.stats["rows_downloaded"] = self.stats.get("rows_downloaded", 0) + max(len(rows1), len(rows2))
return diff

if segment_index is not None:
return super()._bisect_and_diff_segments(
ti, table1, table2, info_tree, level, max_rows, segment_index=segment_index, segment_count=segment_count
)
else:
return super()._bisect_and_diff_segments(ti, table1, table2, info_tree, level, max_rows)
return super()._bisect_and_diff_segments(
ti, table1, table2, info_tree, level, max_rows, segment_index=segment_index, segment_count=segment_count
)

0 comments on commit 43b78af

Please sign in to comment.