<commit_before>from django.conf import settings

__all__ = (
    'TemplateNameResolverMixin',
)

_default_separators = None
def default_separators():
    global _default_separators
    if not _default_separators:
        _default_separators = getattr(settings,
                                      'TEMPLATE_SUFFIX_SEPARATORS',
                                      ('-',))
    return _default_separators

_default_extensions = None
def default_extensions():
    global _default_extensions
    if not _default_extensions:
        _default_separators = getattr(settings,
                                      'TEMPLATE_EXTENSIONS',
                                      ('html',))
    return _default_extensions

class TemplateNameResolverMixin(object):
    """
    Overrides get template name.
    """
    
    template_suffixes = ('',)
    template_suffix_separators = default_separators()
    template_extensions = default_extensions()

    def __template_name_parts(self):
        for suffix in self.template_suffixes:
            for separator in self.template_suffix_separators:
                for extension in self.template_extensions:
                    yield suffix, separator, extension

    def __format_template_name(self, suffix, separator, extension):<commit_msg>Correction where reading from settings<commit_after>from django.conf import settings


__all__ = (
    'TemplateNameResolverMixin',
)


_default_separators = getattr(settings, 'TEMPLATE_SUFFIX_SEPARATORS', ('-',))


_default_extensions = getattr(settings, 'TEMPLATE_EXTENSIONS', ('html',))


class TemplateNameResolverMixin(object):
    """
    Overrides get template name.
    """
    
    template_suffixes = ('',)
    template_suffix_separators = _default_separators
    template_extensions = _default_extensions

    def __template_name_parts(self):
        for suffix in self.template_suffixes:
            for separator in self.template_suffix_separators:
                for extension in self.template_extensions:
                    yield suffix, separator, extension

    def __format_template_name(self, suffix, separator, extension):
{'fraction_non_alphanumeric': 0.07253886010362694, 'fraction_numerical': 0.0, 'mean_word_length': 2.7996422182468694, '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': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3572876', 'n_tokens_mistral': 578, 'n_tokens_neox': 547, 'n_words': 119}