

def after(base=_datetime, diff=None):
    '\n    count datetime after diff args\n    :param base: str/datetime/date\n    :param diff: str\n    :return: datetime\n    '
    _base = parse(base)
    if isinstance(_base, datetime.date):
        _base = midnight(_base)
    result_dict = dp(diff)
    for unit in result_dict:
        _val = result_dict[unit]
        if (not _val):
            continue
        if (unit == 'years'):
            _base = _base.replace(year=(_base.year + _val))
        elif (unit == 'months'):
            if ((_base.month + _val) <= 12):
                _base = _base.replace(month=(_base.month + _val))
            else:
                _month_diff = ((_base.month + _val) - 12)
                _base = _base.replace(year=(_base.year + 1)).replace(month=_month_diff)
        elif (unit in ['days', 'hours', 'minutes', 'seconds']):
            _base = (_base + datetime.timedelta(**{
                unit: _month_diff,
            }))
    return _base

dataset/ETHPy150Open shinux/PyTime/pytime/pytime.py after/VarMisuse@221/327 `_val`->`_month_diff`