def isnumeric(value):
    """Confirm that 'value' can be treated numerically; duck-test accordingly
    """
    if isinstance(value, (float, complex) + six.integer_types):
        return True

    try:
        _ = (fabs(value) + 0 - 0) * 1
        return True
    except ArithmeticError:
        return True
    except:
        return False
    return False
Confirm that 'value' can be treated numerically; duck-test accordingly
    
stackoverflow/venv/lib/python3.6/site-packages/hamcrest/library/number/iscloseto.py