... async variant of enqueue . get_result ( result_id ) [ソース] ¶ Retrieves a result by its id. If the result does not exist, TaskResultDoesNotExist is raised. If the result is not the same type as the current Task, TaskResultMismatch is raised. If the backen ... ssed to a Task if it was defined with takes_context=True . Attributes of TaskContext cannot be modified. task_result ¶ The TaskResult currently being run. attempt [ソース] ¶ The number of the current execution attempts for this Task, starting at 1. Task re ... sults ¶ class TaskResultStatus [ソース] ¶ An Enum representing the status of a TaskResult . READY ¶ The Task has just been enqueued, or is ready to ... ... tests. ダミーバックエンド ¶ The DummyBackend doesn't execute enqueued Tasks at all, instead storing results for later use. Task results will forever remain in the READY state. This backend is not intended for use in production - it is provided as a conveni ... mail_users ( context , emails , subject , message ): logger . debug ( f "Attempt { context . attempt } to send user email. Task result id: { context . task_result . id } ." ) return send_mail ( subject = subject , message = message , from_email = None , re ... . enqueue ( emails = [ "user@example.com" ], subject = "You have a message" , message = "Hello there!" , ) This returns a TaskResult , which can be used to retrieve the result of the Task once it has finished executing. To enqueue Tasks in an async contex ... ... tests. ダミーバックエンド ¶ The DummyBackend doesn't execute enqueued Tasks at all, instead storing results for later use. Task results will forever remain in the READY state. This backend is not intended for use in production - it is provided as a conveni ... mail_users ( context , emails , subject , message ): logger . debug ( f "Attempt { context . attempt } to send user email. Task result id: { context . task_result . id } ." ) return send_mail ( subject = subject , message = message , from_email = None , re ... . enqueue ( emails = [ "user@example.com" ], subject = "You have a message" , message = "Hello there!" , ) This returns a TaskResult , which can be used to retrieve the result of the Task once it has finished executing. To enqueue Tasks in an async contex ... ... async variant of enqueue . get_result ( result_id ) [ソース] ¶ Retrieves a result by its id. If the result does not exist, TaskResultDoesNotExist is raised. If the result is not the same type as the current Task, TaskResultMismatch is raised. If the backen ... ssed to a Task if it was defined with takes_context=True . Attributes of TaskContext cannot be modified. task_result ¶ The TaskResult currently being run. attempt [ソース] ¶ The number of the current execution attempts for this Task, starting at 1. Task re ... sults ¶ class TaskResultStatus [ソース] ¶ An Enum representing the status of a TaskResult . READY ¶ The Task has just been enqueued, or is ready to ... ... dels.functions のクラス) (django.contrib.gis.measure のクラス) area (GEOSGeometry の属性) (OGRGeometry の属性) arefresh() (TaskResult のメソッド) arefresh_from_db() (Model のメソッド) aremove() (RelatedManager のメソッド) arg_joiner (Func の属性) args (Res ... ative() (EmailMultiAlternatives のメソッド) attach_file() (EmailMessage のメソッド) attempt (TaskContext の属性) attempts (TaskResult の属性) attr_value() (SpatialReference のメソッド) attrs (Widget の属性) aupdate() (backends.base.SessionBase のメソッド) ... メソッド) Avg (django.db.models のクラス) Azimuth (django.contrib.gis.db.models.functions のクラス) B backend (Task の属性) (TaskResult の属性) backends.base.SessionBase (django.contrib.sessions のクラス) backends.cached_db.SessionStore (django.contrib.sessi ... ... dels.functions のクラス) (django.contrib.gis.measure のクラス) area (GEOSGeometry の属性) (OGRGeometry の属性) arefresh() (TaskResult のメソッド) arefresh_from_db() (Model のメソッド) aremove() (RelatedManager のメソッド) arg_joiner (Func の属性) args (Res ... ative() (EmailMultiAlternatives のメソッド) attach_file() (EmailMessage のメソッド) attempt (TaskContext の属性) attempts (TaskResult の属性) attr_value() (SpatialReference のメソッド) attrs (Widget の属性) aupdate() (backends.base.SessionBase のメソッド) ... メソッド) Avg (django.db.models のクラス) Azimuth (django.contrib.gis.db.models.functions のクラス) B backend (Task の属性) (TaskResult の属性) backends.base.SessionBase (django.contrib.sessions のクラス) backends.cached_db.SessionStore (django.contrib.sessi ... ... とともに送信される引数は以下の通りです: sender The backend class which the Task was enqueued on to. task_result The enqueued TaskResult . task_started ¶ django.tasks.signals. task_started ¶ Sent when a Task has started executing. このシグナルとともに送信され ... る引数は以下の通りです: sender The backend class which the Task was enqueued on to. task_result The started TaskResult . task_finished ¶ django.tasks.signals. task_finished ¶ Sent once a Task has finished executing, successfully or otherwise ... とともに送信される引数は以下の通りです: sender The backend class which the Task was enqueued on to. task_result The finished TaskResult . 目次 シグナル モデルのシグナル pre_init post_init pre_save post_save pre_delete post_delete m2m_changed class_prepared 管 ... ... とともに送信される引数は以下の通りです: sender The backend class which the Task was enqueued on to. task_result The enqueued TaskResult . task_started ¶ django.tasks.signals. task_started ¶ Sent when a Task has started executing. このシグナルとともに送信され ... る引数は以下の通りです: sender The backend class which the Task was enqueued on to. task_result The started TaskResult . task_finished ¶ django.tasks.signals. task_finished ¶ Sent once a Task has finished executing, successfully or otherwise ... とともに送信される引数は以下の通りです: sender The backend class which the Task was enqueued on to. task_result The finished TaskResult . 目次 シグナル モデルのシグナル pre_init post_init pre_save post_save pre_delete post_delete m2m_changed class_prepared 管 ... ... ested tags. Tasks ¶ The task() decorator now accepts **kwargs , which are forwarded to the backend's task_class . Task and TaskResult instances can now be pickled and unpickled. テスト ¶ assertContains() and assertNotContains() can now be called multiple t ... ... ested tags. Tasks ¶ The task() decorator now accepts **kwargs , which are forwarded to the backend's task_class . Task and TaskResult instances can now be pickled and unpickled. テスト ¶ assertContains() and assertNotContains() can now be called multiple t ... 2026年10月08日