{"repo":"RealOrangeOne/django-tasks","free":true,"listed":false,"github":"https://github.com/RealOrangeOne/django-tasks","clone":"git clone https://github.com/RealOrangeOne/django-tasks.git","description":"A backport of Django's built in Tasks framework","language":"Python","stars":810,"topics":["background-workers","django","django-tasks"],"license":"BSD-3-Clause","category":"productivity","readme_excerpt":"Django Tasks A backport of django.tasks - Django's built-in Tasks framework. Installation The first step is to add django tasks to your INSTALLED APPS . Secondly, you'll need to configure a backend. This connects the tasks to whatever is going to execute them. If omitted, the following configuration is used: A few backends are included by default: - django tasks.backends.dummy.DummyBackend : Don't execute the tasks, just store them. This is especially useful for testing. - django tasks.backends.immediate.ImmediateBackend : Execute the task immediately in the current thread Prior to 0.12.0 , django-tasks-db and django-tasks-rq were also included to provide database and RQ based backends. Usage Defining tasks A task is created with the task decorator. The task decorator accepts a few arguments to customize the task: - priority : The priority of the task (between -100 and 100. Larger numbers are higher priority. 0 by default) - queue name : Whether to run the task on a specific queue - backend : Name of the backend for this task to use (as defined in TASKS ) In addition to the above attributes, run after can be passed to specify a specific time the task should run. Task context Sometimes the running task may need to know context about how it was enqueued. To receive the task context as an argument to your task function, pass takes context to the decorator and ensure the task takes a context as the first argument. The task context has the following attributes: - task result : The","default_branch":null,"files":null,"tree":[],"storefront":"/r/RealOrangeOne","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/RealOrangeOne/django-tasks/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}