<commit_before>import pkg_resources

from django.utils import six
from django.utils.lru_cache import lru_cache


@lru_cache()
def get_backup_strategies():
    entry_points = pkg_resources.get_entry_map('nodeconductor').get('backup_strategies', {})
    strategies = dict((name.upper(), entry_point.load()) for name, entry_point in entry_points.iteritems())
    return strategies<commit_msg>Use new comprehension syntax and six (nc-263)<commit_after>import pkg_resources

from django.utils import six
from django.utils.lru_cache import lru_cache


@lru_cache()
def get_backup_strategies():
    entry_points = pkg_resources.get_entry_map('nodeconductor').get('backup_strategies', {})
    strategies = {name.upper(): entry_point.load() for name, entry_point in six.iteritems(entry_points)}
    return strategies
{'fraction_non_alphanumeric': 0.10532837670384139, 'fraction_numerical': 0.0037174721189591076, 'mean_word_length': 6.481481481481482, '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': '2108921', 'n_tokens_mistral': 255, 'n_tokens_neox': 246, 'n_words': 55}