import math


def _equal(source, target):
    """Treats slightly differing floats as equal."""

    # type-dependent treatment:
    # the lookup server yields floats with lower accuracy then the direct storage broker,
    # i.e. comparison will fail at '1646312878.401044' == '1646312878.401'
    if isinstance(source, float) and isinstance(target, float):
        return math.isclose(source, target, rel_tol=1e-9, abs_tol=0.0)
    else:
        return source == target