From 7a1270a3782f04548c8c9527006cd1ae6a04b51b Mon Sep 17 00:00:00 2001 From: HassanAbouelela Date: Sat, 23 Jul 2022 15:20:09 +0000 Subject: Deploying to docs from @ python-discord/bot-core@94c4b408f1afa604ae6907aa28ab694870af20f2 🚀 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main/output/botcore.utils.scheduling.html | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) (limited to 'main/output/botcore.utils.scheduling.html') diff --git a/main/output/botcore.utils.scheduling.html b/main/output/botcore.utils.scheduling.html index 358a03da..254866e2 100644 --- a/main/output/botcore.utils.scheduling.html +++ b/main/output/botcore.utils.scheduling.html @@ -183,6 +183,7 @@

Other:

@@ -309,7 +310,7 @@

Generic python scheduler.

-class Scheduler(name)[source]#
+class Scheduler(name)[source]#

Bases: object

Schedule the execution of coroutines and keep track of them.

When instantiating a Scheduler, a name must be provided. This name is used to distinguish the @@ -323,7 +324,7 @@ the same ID used to schedule it.

Any exception raised in a scheduled task is logged when the task is done.

-__contains__(task_id)[source]#
+__contains__(task_id)[source]#

Return True if a task with the given task_id is currently scheduled.

Parameters:
@@ -340,7 +341,7 @@ the same ID used to schedule it.

-__init__(name)[source]#
+__init__(name)[source]#

Initialize a new Scheduler instance.

Parameters:
@@ -351,7 +352,7 @@ the same ID used to schedule it.

-cancel(task_id)[source]#
+cancel(task_id)[source]#

Unschedule the task identified by task_id. Log a warning if the task doesn’t exist.

Parameters:
@@ -365,7 +366,7 @@ the same ID used to schedule it.

-cancel_all()[source]#
+cancel_all()[source]#

Unschedule all known tasks.

Return type:
@@ -376,7 +377,7 @@ the same ID used to schedule it.

-schedule(task_id, coroutine)[source]#
+schedule(task_id, coroutine)[source]#

Schedule the execution of a coroutine.

If a task with task_id already exists, close coroutine instead of scheduling it. This prevents unawaited coroutine warnings. Don’t pass a coroutine that’ll be re-used elsewhere.

@@ -395,7 +396,7 @@ prevents unawaited coroutine warnings. Don’t pass a coroutine that’ll be re-
-schedule_at(time, task_id, coroutine)[source]#
+schedule_at(time, task_id, coroutine)[source]#

Schedule coroutine to be executed at the given time.

If time is timezone aware, then use that timezone to calculate now() when subtracting. If time is naĂŻve, then use UTC.

@@ -418,7 +419,7 @@ prevents unawaited coroutine warnings. Don’t pass a coroutine that’ll be re-
-schedule_later(delay, task_id, coroutine)[source]#
+schedule_later(delay, task_id, coroutine)[source]#

Schedule coroutine to be executed after delay seconds.

If a task with task_id already exists, close coroutine instead of scheduling it. This prevents unawaited coroutine warnings. Don’t pass a coroutine that’ll be re-used elsewhere.

@@ -440,7 +441,7 @@ prevents unawaited coroutine warnings. Don’t pass a coroutine that’ll be re-
-create_task(coro, *, suppressed_exceptions=(), event_loop=None, **kwargs)[source]#
+create_task(coro, *, suppressed_exceptions=(), event_loop=None, **kwargs)[source]#

Wrapper for creating an asyncio.Task which logs exceptions raised in the task.

If the event_loop kwarg is provided, the task is created from that event loop, otherwise the running loop is used.

-- cgit v1.2.3