def validate_positive_float_or_zero(option, value):
    """Validates that 'value' is 0 or a positive float, or can be converted to
    0 or a positive float.
    """
    if value == 0 or value == "0":
        return 0
    return validate_positive_float(option, value)
Validates that 'value' is 0 or a positive float, or can be converted to
    0 or a positive float.
    
stackoverflow/venv/lib/python3.6/site-packages/pymongo/common.py