def autotype(s):

    if not isinstance(s, str):
        return s

    if s.isdigit():
        return int(s)

    try:
        return float(s)
    except ValueError:
        return s
Turn the device off.
dataset/ETHPy150Open moskytw/clime/clime/util.py/autotype--crossover with--dataset/ETHPy150Open home-assistant/home-assistant/homeassistant/components/light/scsgate.py/SCSGateLight.turn_off