Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion datacompy/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,11 @@ def get_column_tolerance(column: str, tol_dict: Dict[str, float]) -> float:
The tolerance value for the specified column, or the "default" tolerance if the column is not found.
Returns 0 if neither the column nor "default" is present in the dictionary.
"""
return tol_dict.get(column, tol_dict.get("default", 0.0))
if column in tol_dict:
return tol_dict[column]
if "default" in tol_dict:
return tol_dict["default"]
return 0.0


def _validate_tolerance_parameter(
Expand Down