<commit_before>from background_task.models_completed import CompletedTask
from django.core.management.base import BaseCommand
from django.urls import reverse


class Command(BaseCommand):
    help = 'Send notifications to inform admins about taks that errored'

    def handle(self, *args, **options):
        broken_tasks = CompletedTask\
            .objects.exclude(last_error='')\
            .order_by('-run_at')
<commit_msg>apps/contrib: Update background task import<commit_after>from background_task.models import CompletedTask
from django.core.management.base import BaseCommand
from django.urls import reverse


class Command(BaseCommand):
    help = 'Send notifications to inform admins about taks that errored'

    def handle(self, *args, **options):
        broken_tasks = CompletedTask\
            .objects.exclude(last_error='')\
            .order_by('-run_at')

{'fraction_non_alphanumeric': 0.08863636363636364, 'fraction_numerical': 0.0, 'mean_word_length': 3.840659340659341, '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': '2894410', 'n_tokens_mistral': 245, 'n_tokens_neox': 233, 'n_words': 68}