def to_bool(value):
    """
    Converts 'something' to boolean. Raises exception for invalid formats
    Possible True  values: 1, True, '1', 'TRue', 'yes', 'y', 't'
    Possible False values: 0, False, None, [], {}, '', '0', 'faLse', 'no', 'n', 'f', 0.0
    """
    if type(value) == type(''):
        if value.lower() in ("yes", "y", "true",  "t", "1"):
            return True
        if value.lower() in ("no",  "n", "false", "f", "0", "none", ""):
            return False
        raise Exception('Invalid value for boolean conversion: ' + value)
    return bool(value)