def truthiness(s):
    try:
        return str(s).lower() in ['true', 't', '1']
    except (TypeError, ValueError, UnicodeEncodeError):
        return False
Registers a listener method which will be notified when a packet of
dataset/ETHPy150Open rehandalal/buchner/buchner/helpers.py/truthiness--crossover with--dataset/ETHPy150Open ammaraskar/pyCraft/minecraft/networking/connection.py/Connection.register_packet_listener