def add_ago_to_since(since: str) -> str:
    """
    Backwards compatibility hack. Without this slices with since: 7 days will
    be treated as 7 days in the future.

    :param str since:
    :returns: Since with ago added if necessary
    :rtype: str
    """
    since_words = since.split(' ')
    grains = ['days', 'years', 'hours', 'day', 'year', 'weeks']
    if (len(since_words) == 2 and since_words[1] in grains):
        since += ' ago'
    return since
def add_ago_to_since ( since : str ) -> str : since_words = since . split ( ' ' ) grains = [ 'days' , 'years' , 'hours' , 'day' , 'year' , 'weeks' ] if ( len ( since_words ) == 2 and since_words [ 1 ] in grains ) : since += ' ago' return since
Backwards compatibility hack. Without this slices with since: 7 days will
    be treated as 7 days in the future.

    :param str since:
    :returns: Since with ago added if necessary
    :rtype: str