flamingo-run/django-cloud-tasks

View on GitHub
django_cloud_tasks/management/commands/initialize_tasks.py

Summary

Maintainability
A
0 mins
Test Coverage
from typing import List

from django_cloud_tasks.management.commands import BaseInitCommand


class Command(BaseInitCommand):
    action = "configure"
    name = "tasks"

    def perform_init(self, app_config, *args, **options) -> List[str]:
        report = []
        report.extend(app_config.schedule_tasks())
        report.extend(app_config.initialize_subscribers())
        return report