def local_sleep(interval, fuzz_proportion=.2):
    """
    Add some sleep to simulate running on a server.
    """
    if fuzz_proportion:
        max_fuzz_distance = interval * fuzz_proportion
        interval += random.uniform(-max_fuzz_distance, max_fuzz_distance)

    if request.url_root in "localhost:5000":
        logger.debug(u"sleeping on local for {second} seconds".format(
            second=interval))
        sleep(interval)
dataset/ETHPy150Open Impactstory/total-impact-webapp/util.py/local_sleep/swapped operands of `in`