Skip to content

Commit

Permalink
add logging for no match columns
Browse files Browse the repository at this point in the history
  • Loading branch information
fdosani committed Feb 26, 2025
1 parent 95f3a92 commit 81d4914
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions datacompy/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -602,6 +602,7 @@ def all_mismatch(self, ignore_matching_cols: bool = False) -> pd.DataFrame:
f"Column {orig_col_name} is equal in df1 and df2. It will not be added to the result."
)
if len(match_list) == 0:
LOG.info("No match columns found, returning mismatches based on unq_rows")
return pd.concat(
[
self.df1_unq_rows[self.join_columns],
Expand Down
1 change: 1 addition & 0 deletions datacompy/polars.py
Original file line number Diff line number Diff line change
Expand Up @@ -594,6 +594,7 @@ def all_mismatch(self, ignore_matching_cols: bool = False) -> pl.DataFrame:
f"Column {orig_col_name} is equal in df1 and df2. It will not be added to the result."
)
if len(match_list) == 0:
LOG.info("No match columns found, returning mismatches based on unq_rows")
return pl.concat(
[
self.df1_unq_rows.select(self.join_columns),
Expand Down

0 comments on commit 81d4914

Please sign in to comment.