from datetime import date, timedelta


def dategenerator(start, end, step=1, desc=False):
    delta = timedelta(abs(step))
    end = max(start, end)
    if desc:
        dt = end
        while dt >= start:
            yield dt
            dt -= delta
    else:
        dt = start
        while dt <= end:
            yield dt
            dt += delta


def default_parse_interval(dt, delta=0):
    if delta:
        return dt + timedelta(delta)
    else:
        return dt

a8f82d6ee7de9b8ef2aceff2ab6492e2db658d80
<mask token>

<mask token>


def default_parse_interval(dt, delta=0):
    if delta:
        return dt + timedelta(delta)
    else:
        return dt

<mask token>


def dategenerator(start, end, step=1, desc=False):
    delta = timedelta(abs(step))
    end = max(start, end)
    if desc:
        dt = end
        while dt >= start:
            yield dt
            dt -= delta
    else:
        dt = start
        while dt <= end:
            yield dt
            dt += delta


def default_parse_interval(dt, delta=0):
    if delta:
        return dt + timedelta(delta)
    else:
        return dt

from datetime import date, timedelta


def dategenerator(start, end, step=1, desc=False):
    delta = timedelta(abs(step))
    end = max(start, end)
    if desc:
        dt = end
        while dt >= start:
            yield dt
            dt -= delta
    else:
        dt = start
        while dt <= end:
            yield dt
            dt += delta


def default_parse_interval(dt, delta=0):
    if delta:
        return dt + timedelta(delta)
    else:
        return dt
