Example #1
0
def c():
    a = ChangedTime('test', pd_now(UTC))
    w1 = a.add_watch(1)
    w2 = a.add_watch(3)

    yield a

    # cancel the rest of the running tasks
    w1.cancel()
    w2.cancel()
Example #2
0
def c():
    a = ChangedTime('test', datetime.now(tz=pytz.utc))
    w1 = a.add_watch(1)
    w2 = a.add_watch(3)

    yield a

    # cancel the rest of the running tasks
    w1.cancel()
    w2.cancel()