<commit_before>from .parse import Node
from .library import Library

import datetime

register = Library()


@register.tag(name='now')
def now(token, parser):

    def _now(context):
        # resolve bits
        val = datetime.datetime.now()
        return val.strftime(token[0])

    return _now<commit_msg>Update defaulttags to use new helper<commit_after>from .library import Library

import datetime

register = Library()


@register.tag(name='now')
def now(parser, token):

    args, kwargs = parser.parse_args(token)

    def _now(context):
        a, k = parser.resolve_args(context, args, kwargs)
        val = datetime.datetime.now()
        return val.strftime(a[0])

    return _now
{'fraction_non_alphanumeric': 0.1093525179856115, 'fraction_numerical': 0.0028776978417266188, 'mean_word_length': 3.3773584905660377, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6163430', 'n_tokens_mistral': 213, 'n_tokens_neox': 205, 'n_words': 58}