Add intended_date_kwarg field to Schedule (#62)

Co-authored-by: Marc Sabatier <marc.sabatier@eco-adapt.com>
This commit is contained in:
msabatier
2023-01-17 22:52:11 +01:00
committed by GitHub
parent 865b1a5ba8
commit a013591de5
9 changed files with 455 additions and 357 deletions

View File

@@ -691,6 +691,8 @@ def scheduler(broker: Broker = None):
if type(args) != tuple:
args = (args,)
q_options = kwargs.get("q_options", {})
if s.intended_date_kwarg:
kwargs[s.intended_date_kwarg] = s.next_run.isoformat()
if s.hook:
q_options["hook"] = s.hook
# set up the next run time

View File

@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-11-12 01:47+0000\n"
"POT-Creation-Date: 2023-01-15 23:35+0100\n"
"PO-Revision-Date: 2018-08-05 18:28+0200\n"
"Last-Translator: Jonas Winkler\n"
"Language-Team: \n"
@@ -17,177 +17,166 @@ msgstr ""
"X-Generator: Poedit 2.1.1\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#: django_q/admin.py:43
#: admin.py:43
msgid "Resubmit selected tasks to queue"
msgstr "Ausgewählte Aufgaben erneut ausführen"
#: django_q/admin.py:98 django_q/models.py:228
#: admin.py:107 models.py:293
#, fuzzy
#| msgid "Success"
msgid "success"
msgstr "erfolg"
#: django_q/admin.py:109 django_q/models.py:230
#: admin.py:119 models.py:295
msgid "last_run"
msgstr ""
#: django_q/cluster.py:77
#: cluster.py:76
#, python-format
msgid "Q Cluster %(name)s starting."
msgstr "Q-Cluster %(name)s wird gestartet."
#: django_q/cluster.py:85
#: cluster.py:84
#, fuzzy, python-format
#| msgid "Q Cluster-{} stopping."
msgid "Q Cluster %(name)s stopping."
msgstr "Q-Cluster {name} wird gestoppt."
#: django_q/cluster.py:88
#: cluster.py:87
#, python-format
msgid "Q Cluster %(name)s has stopped."
msgstr "Q-Cluster %(name)s wurde gestoppt."
#: django_q/cluster.py:96
#: cluster.py:94
#, python-format
msgid "%(name)s got signal %(signal)s"
msgstr "%(name)s erhielt das Signal %(signal)s"
#: django_q/cluster.py:219
#: cluster.py:221
#, python-format
msgid "reincarnated monitor %(name)s after sudden death"
msgstr "Monitor %(name)s wurde nach unerwartetem Absturz neu gestartet"
#: django_q/cluster.py:222
#: cluster.py:227
#, python-format
msgid "reincarnated pusher %(name)s after sudden death"
msgstr "Pusher %(name)s wurde nach unerwartetem Absturz neu gestartet"
#: django_q/cluster.py:229
#: cluster.py:238
#, python-format
msgid "reincarnated worker %(name)s after timeout"
msgstr "Worker %(name)s wurde nach Zeitüberschreitung neu gestartet"
#: django_q/cluster.py:231
#: cluster.py:242
#, python-format
msgid "recycled worker %(name)s"
msgstr "Worker %(name)s wurde wiederverwendet"
#: django_q/cluster.py:233
#: cluster.py:245
#, python-format
msgid "reincarnated worker %(name)s after death"
msgstr "Worker %(name)s wurde nach unerwartetem Absturz neu gestartet"
#: django_q/cluster.py:256
#: cluster.py:269
#, python-format
msgid "%(name)s guarding cluster %(cluster_name)s"
msgstr "%(name)s beschützt das Cluster %(cluster_name)s"
#: django_q/cluster.py:261
#: cluster.py:278
#, python-format
msgid "Q Cluster %(cluster_name)s running."
msgstr "Q-Cluster %(cluster_name)s läuft."
#: django_q/cluster.py:295
#: cluster.py:314
#, python-format
msgid "%(name)s stopping cluster processes"
msgstr "%(name)s hält Cluster-Prozesse an"
#: django_q/cluster.py:320
#: cluster.py:339
#, python-format
msgid "%(name)s waiting for the monitor."
msgstr "%(name)s wartet auf den Monitor."
#: django_q/cluster.py:342
#: cluster.py:362
#, python-format
msgid "%(process_name)s pushing tasks at %(id)s"
msgstr "%(process_name)s veröffentlicht Aufagaben auf %(id)s"
#: django_q/cluster.py:363
#: cluster.py:386
#, python-format
msgid "queueing from %(list_key)s"
msgstr "Einreihen von %(list_key)s"
#: django_q/cluster.py:366
#: cluster.py:390
#, python-format
msgid "%(name)s stopped pushing tasks"
msgstr "%(name)s veröffentlicht keine Aufgaben mehr"
#: django_q/cluster.py:378
#: cluster.py:403
#, python-format
msgid "%(name)s monitoring at %(id)s"
msgstr "%(name)s beobachtet auf %(id)s"
#: django_q/cluster.py:395
#: cluster.py:422
#, python-format
msgid "Processed '%(info_name)s' (%(task_name)s)"
msgstr "[%(task_name)s] - '%(info_name)s' wurde verarbeitet"
#: django_q/cluster.py:398
#: cluster.py:428
#, python-format
msgid "Failed '%(info_name)s' (%(task_name)s) - %(task_result)s"
msgstr "'%(info_name)s' (%(task_name)s) ist fehlgeschlagen - %(task_result)s"
#: django_q/cluster.py:399
#: cluster.py:435
#, python-format
msgid "%(name)s stopped monitoring results"
msgstr "%(name)s überwacht keine Ergebnisse mehr"
#: django_q/cluster.py:413
#: cluster.py:451
#, python-format
msgid "%(proc_name)s ready for work at %(id)s"
msgstr "%(proc_name)s ist bereit für Arbeit auf %(id)s"
#: django_q/cluster.py:425
#: cluster.py:466
#, python-format
msgid "%(proc_name)s processing '%(func_name)s' (%(task_name)s)"
msgstr "%(proc_name)s verarbeitet '%(func_name)s' (%(task_name)s)"
#: django_q/cluster.py:440
#, python-format
msgid ""
"Could not process '%(func_name)s'. Check the location of the function and "
"the args/kwargs."
msgstr ""
"Konnte '%(func_name)s' nicht verarbeiten. Überprüfen Sie den Ort der "
"Funktion und die args/kwargs."
#: django_q/cluster.py:456
#: cluster.py:507
#, python-format
msgid "%(proc_name)s stopped doing work"
msgstr "%(proc_name)s hat die Arbeit beendet"
#: django_q/cluster.py:649 django_q/models.py:144
msgid "Please install croniter to enable cron expressions"
msgstr "Bitte installieren Sie croniter, um Cron-Ausdrücke zu aktivieren"
#: django_q/cluster.py:672
#: cluster.py:712
#, python-format
msgid "%(process_name)s failed to create a task from schedule [%(schedule)s]"
msgstr ""
"%(process_name)s konnte keine Aufgabe von Zeitplan [%(schedule)s] erstellen"
#: django_q/cluster.py:678
#, python-format
msgid "%(process_name)s created a task from schedule [%(schedule)s]"
#: cluster.py:723
#, fuzzy, python-format
#| msgid "%(process_name)s created a task from schedule [%(schedule)s]"
msgid ""
"%(process_name)s created task %(task_name)s from schedule [%(schedule)s]"
msgstr ""
"%(process_name)s hat eine Aufgabe des Zeitplans [%(schedule)s] erstellt"
#: django_q/cluster.py:718
#: cluster.py:769
msgid "Skipping cpu affinity because psutil was not found."
msgstr "Cpu-Affinität wird übersprungen, da psutil nicht gefunden wurde."
#: django_q/cluster.py:723
#: cluster.py:774
msgid "Faking cpu affinity because it is not supported on this platform"
msgstr ""
"Vortäuschen von CPU-Affinität, da diese auf dieser Plattform nicht "
"unterstützt wird"
#: django_q/cluster.py:744
#: cluster.py:796
#, python-format
msgid "%(pid)s will use cpu %(affinity)s"
msgstr "%(pid)s wird CPU %(affinity)s benutzen"
#: django_q/conf.py:85
#: conf.py:85
#, python-format
msgid ""
"SAVE_LIMIT_PER (%(option)s) is not a valid option. Options are: 'group', "
@@ -197,291 +186,307 @@ msgstr ""
"'group', 'name', 'func' und None. Standard ist None."
#. Translators: Cluster status descriptions
#: django_q/conf.py:194
#: conf.py:202
msgid "Starting"
msgstr "Wird gestartet"
#: django_q/conf.py:195
#: conf.py:203
msgid "Working"
msgstr "Arbeitet"
#: django_q/conf.py:196
#: conf.py:204
msgid "Idle"
msgstr "Leerlauf"
#: django_q/conf.py:197
#: conf.py:205
msgid "Stopped"
msgstr "Gestoppt"
#: django_q/conf.py:198
#: conf.py:206
msgid "Stopping"
msgstr "Wird gestoppt"
#. Translators: help text for qcluster management command
#: django_q/management/commands/qcluster.py:9
#: management/commands/qcluster.py:9
msgid "Starts a Django Q Cluster."
msgstr "Startet ein Django-Q-Cluster."
#. Translators: help text for qinfo management command
#: django_q/management/commands/qinfo.py:11
#: management/commands/qinfo.py:11
msgid "General information over all clusters."
msgstr "Allgemeine Informationen über alle Cluster"
#. Translators: help text for qmemory management command
#: django_q/management/commands/qmemory.py:9
#: management/commands/qmemory.py:9
msgid "Monitors Q Cluster memory usage"
msgstr "Überwacht die Speichernutzung von Q Cluster"
#. Translators: help text for qmonitor management command
#: django_q/management/commands/qmonitor.py:9
#: management/commands/qmonitor.py:9
msgid "Monitors Q Cluster activity"
msgstr "Q-Cluster aktiv überwachen"
#: django_q/models.py:119
#: models.py:125
msgid "Successful task"
msgstr "Erfolgreiche Aufgabe"
#: django_q/models.py:120
#: models.py:126
msgid "Successful tasks"
msgstr "Erfolgreiche Aufgaben"
#: django_q/models.py:135
#: models.py:141
msgid "Failed task"
msgstr "Fehlgeschlagene Aufgabe"
#: django_q/models.py:136
#: models.py:142
msgid "Failed tasks"
msgstr "Fehlgeschlagene Aufgaben"
#: django_q/models.py:160
#: models.py:150 models.py:234
msgid "Please install croniter to enable cron expressions"
msgstr "Bitte installieren Sie croniter, um Cron-Ausdrücke zu aktivieren"
#: models.py:170
msgid "e.g. 1, 2, 'John'"
msgstr "zum Beispiel 1, 2, 'John'"
#: django_q/models.py:162
#: models.py:172
msgid "e.g. x=1, y=2, name='John'"
msgstr "zum Beispiel x=1, y=2, name='John'"
#: django_q/models.py:176
#: models.py:186
msgid "Once"
msgstr "Einmal"
#: django_q/models.py:177
#: models.py:187
msgid "Minutes"
msgstr "Minuten"
#: django_q/models.py:178
#: models.py:188
msgid "Hourly"
msgstr "Stündlich"
#: django_q/models.py:179
#: models.py:189
msgid "Daily"
msgstr "Täglich"
#: django_q/models.py:180
#: models.py:190
msgid "Weekly"
msgstr "Wöchentlich"
#: django_q/models.py:181
#: models.py:191
msgid "Biweekly"
msgstr "Zweiwöchentlich"
#: django_q/models.py:182
#: models.py:192
msgid "Monthly"
msgstr "Monatlich"
#: django_q/models.py:183
#: models.py:193
msgid "Bimonthly"
msgstr "Zweimonatlich"
#: django_q/models.py:184
#: models.py:194
msgid "Quarterly"
msgstr "Vierteljährlich"
#: django_q/models.py:185
#: models.py:195
msgid "Yearly"
msgstr "Jährlich"
#: django_q/models.py:186
#: models.py:196
msgid "Cron"
msgstr "Cron"
#: django_q/models.py:189
#: models.py:199
msgid "Schedule Type"
msgstr "Zeitplan-Typ"
#: django_q/models.py:192
#: models.py:202
msgid "Number of minutes for the Minutes type"
msgstr "Anzahl Minuten für den Typ 'Minuten'"
#: django_q/models.py:195
#: models.py:205
msgid "Repeats"
msgstr "Wiederhohlungen"
#: django_q/models.py:195
#: models.py:205
msgid "n = n times, -1 = forever"
msgstr "n = n mal, -1 = für immer"
#: django_q/models.py:198
#: models.py:208
msgid "Next Run"
msgstr "Nächste Ausführung"
#: django_q/models.py:205
#: models.py:215
msgid "Cron expression"
msgstr "Cron-Ausdruck"
#: django_q/models.py:235
#: models.py:224
msgid "Name of kwarg to pass intended schedule date"
msgstr ""
#: models.py:299
msgid "Scheduled task"
msgstr "Geplante Aufgabe"
#: django_q/models.py:236
#: models.py:300
msgid "Scheduled tasks"
msgstr "Geplante Aufgaben"
#: django_q/models.py:262
#: models.py:326
msgid "Queued task"
msgstr "Eingereihte Aufgabe"
#: django_q/models.py:263
#: models.py:327
msgid "Queued tasks"
msgstr "Eingereihte Aufgaben"
#: django_q/monitor.py:62 django_q/monitor.py:339
#: monitor.py:64 monitor.py:348
msgid "Host"
msgstr "Host"
#: django_q/monitor.py:66 django_q/monitor.py:343 django_q/monitor.py:450
#: monitor.py:68 monitor.py:352 monitor.py:459
msgid "Id"
msgstr "Id"
#: django_q/monitor.py:70
#: monitor.py:72
msgid "State"
msgstr "Status"
#: django_q/monitor.py:74
#: monitor.py:76
msgid "Pool"
msgstr "Pool"
#: django_q/monitor.py:78
#: monitor.py:80
msgid "TQ"
msgstr "TQ"
#: django_q/monitor.py:82
#: monitor.py:84
msgid "RQ"
msgstr "RQ"
#: django_q/monitor.py:86
#: monitor.py:88
msgid "RC"
msgstr "RC"
#: django_q/monitor.py:90
#: monitor.py:92
msgid "Up"
msgstr "Up"
#: django_q/monitor.py:170 django_q/monitor.py:279
#: monitor.py:172 monitor.py:286
msgid "Queued"
msgstr "Eingereiht"
#: django_q/monitor.py:178
#: monitor.py:180
msgid "Success"
msgstr "Erfolg"
#: django_q/monitor.py:188 django_q/monitor.py:287
#: monitor.py:190 monitor.py:294
msgid "Failures"
msgstr "Fehlschläge"
#: django_q/monitor.py:199 django_q/monitor.py:485
#: monitor.py:201 monitor.py:498
msgid "[Press q to quit]"
msgstr "[Drücken Sie q zum Beenden]"
#: django_q/monitor.py:223
#: monitor.py:227
msgid "day"
msgstr "Tag"
#: django_q/monitor.py:244
#: monitor.py:248
msgid "second"
msgstr "Sekunde"
#: django_q/monitor.py:247
#: monitor.py:251
msgid "minute"
msgstr "Minute"
#: django_q/monitor.py:250
#: monitor.py:254
msgid "hour"
msgstr "Stunde"
#: django_q/monitor.py:260
#: monitor.py:263
#, python-format
msgid "-- %(prefix)s %(version)s on %(info)s --"
msgstr "-- %(prefix)s %(version)s auf %(info)s --"
#: django_q/monitor.py:266
#: monitor.py:273
msgid "Clusters"
msgstr "Cluster"
#: django_q/monitor.py:270
#: monitor.py:277
msgid "Workers"
msgstr "Arbeiter"
#: django_q/monitor.py:274
#: monitor.py:281
msgid "Restarts"
msgstr "Neustarts"
#: django_q/monitor.py:283
#: monitor.py:290
msgid "Successes"
msgstr "Erfolge"
#: django_q/monitor.py:292
#: monitor.py:299
msgid "Schedules"
msgstr "Zeitpläne"
#: django_q/monitor.py:296
#: monitor.py:303
#, python-format
msgid "Tasks/%(per)s"
msgstr "Aufgaben/%(per)s"
#: django_q/monitor.py:300
#: monitor.py:307
msgid "Avg time"
msgstr "Durchschnittl. Zeit"
#: django_q/monitor.py:348
#: monitor.py:357
msgid "Available (%)"
msgstr "Verfügbar (%)"
#: django_q/monitor.py:354
#: monitor.py:363
msgid "Available (MB)"
msgstr "Verfügbar (MB)"
#: django_q/monitor.py:359
#: monitor.py:368
msgid "Total (MB)"
msgstr "Insgesamt (MB)"
#: django_q/monitor.py:364
#: monitor.py:373
msgid "Sentinel (MB)"
msgstr "Sentinel (MB)"
#: django_q/monitor.py:370
#: monitor.py:379
msgid "Monitor (MB)"
msgstr "Monitor (MB)"
#: django_q/monitor.py:376
#: monitor.py:385
msgid "Workers (MB)"
msgstr "Arbeiter (MB)"
#: django_q/monitor.py:478
#: monitor.py:487
#, python-format
msgid "Available lowest (): %(memory_percent)s ((at)s)"
msgstr "Niedrigste verfügbar (): %(memory_percent)s ((at)s)"
#: django_q/monitor.py:496
#: monitor.py:509
msgid "No clusters appear to be running."
msgstr "Es scheinen keine Cluster zu laufen."
#: django_q/signals.py:22
#: signals.py:22
#, python-format
msgid "malformed return hook '%(hook)s' for [%(name)s]"
msgstr "Ungültiger Return-Hook '%(hook)s' für [%(name)s]"
#: django_q/signals.py:30
#: signals.py:30
#, python-format
msgid "return hook %(hook)s failed on [%(name)s] because %(error)s"
msgstr "Return-Hook %(hook)s für [%(name)s] ist gescheitert: %(error)s"
#, python-format
#~ msgid ""
#~ "Could not process '%(func_name)s'. Check the location of the function and "
#~ "the args/kwargs."
#~ msgstr ""
#~ "Konnte '%(func_name)s' nicht verarbeiten. Überprüfen Sie den Ort der "
#~ "Funktion und die args/kwargs."

View File

@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-11-12 01:47+0000\n"
"POT-Creation-Date: 2023-01-15 23:35+0100\n"
"PO-Revision-Date: 2018-08-05 18:28+0200\n"
"Last-Translator: Thierry BOULOGNE <contact@tng-concepts.com>\n"
"Language-Team: \n"
@@ -17,176 +17,164 @@ msgstr ""
"X-Generator: Poedit 2.1.1\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#: django_q/admin.py:43
#: admin.py:43
msgid "Resubmit selected tasks to queue"
msgstr "Resoumettre les tâches sélectionnées à la file d'attente"
#: django_q/admin.py:98 django_q/models.py:228
#: admin.py:107 models.py:293
#, fuzzy
#| msgid "Success"
msgid "success"
msgstr "succès"
#: django_q/admin.py:109 django_q/models.py:230
#: admin.py:119 models.py:295
msgid "last_run"
msgstr ""
#: django_q/cluster.py:77
#: cluster.py:76
#, python-format
msgid "Q Cluster %(name)s starting."
msgstr "Démarrage de Q Cluster-%(name)s."
#: django_q/cluster.py:85
#: cluster.py:84
#, python-format
msgid "Q Cluster %(name)s stopping."
msgstr "Arrêt de Q Cluster-%(name)s."
#: django_q/cluster.py:88
#: cluster.py:87
#, python-format
msgid "Q Cluster %(name)s has stopped."
msgstr "Q Cluster-%(name)s a été arrêté."
#: django_q/cluster.py:96
#: cluster.py:94
#, python-format
msgid "%(name)s got signal %(signal)s"
msgstr "%(name)s à reçu le signal %(signal)s"
#: django_q/cluster.py:219
#: cluster.py:221
#, python-format
msgid "reincarnated monitor %(name)s after sudden death"
msgstr "moniteur réintégré %(name)s après un arrêt intempestif"
#: django_q/cluster.py:222
#: cluster.py:227
#, python-format
msgid "reincarnated pusher %(name)s after sudden death"
msgstr "pousseur réintégré %(name)s après un arrêt intempestif"
#: django_q/cluster.py:229
#: cluster.py:238
#, python-format
msgid "reincarnated worker %(name)s after timeout"
msgstr "processus réintégré %(name)s après un arrêt une attente trop longue"
#: django_q/cluster.py:231
#: cluster.py:242
#, python-format
msgid "recycled worker %(name)s"
msgstr "processus recyclé %(name)s"
#: django_q/cluster.py:233
#: cluster.py:245
#, python-format
msgid "reincarnated worker %(name)s after death"
msgstr "processus réintégré %(name)s après arrêt"
#: django_q/cluster.py:256
#: cluster.py:269
#, python-format
msgid "%(name)s guarding cluster %(cluster_name)s"
msgstr "%(name)s surveillance du cluster à %(cluster_name)s"
#: django_q/cluster.py:261
#: cluster.py:278
#, python-format
msgid "Q Cluster %(cluster_name)s running."
msgstr "Démarrage de Q Cluster-%(cluster_name)s."
#: django_q/cluster.py:295
#: cluster.py:314
#, python-format
msgid "%(name)s stopping cluster processes"
msgstr "%(name)s arrêt des processus de cluster"
#: django_q/cluster.py:320
#: cluster.py:339
#, python-format
msgid "%(name)s waiting for the monitor."
msgstr "%(name)s en attente du moniteur."
#: django_q/cluster.py:342
#: cluster.py:362
#, python-format
msgid "%(process_name)s pushing tasks at %(id)s"
msgstr "%(process_name)s tâche envoyé à %(id)s"
#: django_q/cluster.py:363
#: cluster.py:386
#, python-format
msgid "queueing from %(list_key)s"
msgstr "mise en file d'attente de %(list_key)s"
#: django_q/cluster.py:366
#: cluster.py:390
#, python-format
msgid "%(name)s stopped pushing tasks"
msgstr "%(name)s a cessé de pousser les tâches"
#: django_q/cluster.py:378
#: cluster.py:403
#, python-format
msgid "%(name)s monitoring at %(id)s"
msgstr "%(name)s Surveillance de %(id)s"
#: django_q/cluster.py:395
#: cluster.py:422
#, python-format
msgid "Processed '%(info_name)s' (%(task_name)s)"
msgstr "traité '%(info_name)s' (%(task_name)s)"
#: django_q/cluster.py:398
#: cluster.py:428
#, python-format
msgid "Failed '%(info_name)s' (%(task_name)s) - %(task_result)s"
msgstr "Manqué '%(info_name)s' (%(task_name)s) - %(task_result)s"
#: django_q/cluster.py:399
#: cluster.py:435
#, python-format
msgid "%(name)s stopped monitoring results"
msgstr "%(name)s arrêt des résultats de surveillance"
#: django_q/cluster.py:413
#: cluster.py:451
#, python-format
msgid "%(proc_name)s ready for work at %(id)s"
msgstr "%(proc_name)s prêt pour le travail à %(id)s"
#: django_q/cluster.py:425
#: cluster.py:466
#, python-format
msgid "%(proc_name)s processing '%(func_name)s' (%(task_name)s)"
msgstr "%(proc_name)s en traitement '%(func_name)s' (%(task_name)s)"
#: django_q/cluster.py:440
#, python-format
msgid ""
"Could not process '%(func_name)s'. Check the location of the function and "
"the args/kwargs."
msgstr ""
"Impossible de traiter '%(func_name)s'. Vérifiez l'emplacement de la fonction "
"et les args/kwargs."
#: django_q/cluster.py:456
#: cluster.py:507
#, python-format
msgid "%(proc_name)s stopped doing work"
msgstr "%(proc_name)s arrêté de travailler"
#: django_q/cluster.py:649 django_q/models.py:144
msgid "Please install croniter to enable cron expressions"
msgstr "Veuillez installer croniter pour activer les expressions croniques."
#: django_q/cluster.py:672
#: cluster.py:712
#, python-format
msgid "%(process_name)s failed to create a task from schedule [%(schedule)s]"
msgstr ""
"%(process_name)s Echec de la création d'une tâche à partir de Schedule "
"[%(schedule)s]"
#: django_q/cluster.py:678
#: cluster.py:723
#, python-format
msgid "%(process_name)s created a task from schedule [%(schedule)s]"
msgstr "%(process_name)s a créé une tâche à partir de Schedule [%(schedule)s]"
msgid ""
"%(process_name)s created task %(task_name)s from schedule [%(schedule)s]"
msgstr "%(process_name)s a créé la tâche %(task_name)s à partir de Schedule [%(schedule)s]"
#: django_q/cluster.py:718
#: cluster.py:769
msgid "Skipping cpu affinity because psutil was not found."
msgstr "Sauter l'affinité du processeur parce que psutil n'a pas été trouvé."
#: django_q/cluster.py:723
#: cluster.py:774
msgid "Faking cpu affinity because it is not supported on this platform"
msgstr ""
"Simulation de l'affinité du processeur parce qu'elle n'est pas supportée sur "
"cette plateforme."
#: django_q/cluster.py:744
#: cluster.py:796
#, python-format
msgid "%(pid)s will use cpu %(affinity)s"
msgstr "%(pid)s utilisera le CPU %(affinity)s"
#: django_q/conf.py:85
#: conf.py:85
#, python-format
msgid ""
"SAVE_LIMIT_PER (%(option)s) is not a valid option. Options are: 'group', "
@@ -196,299 +184,316 @@ msgstr ""
"'group', 'name', 'func' et None. La valeur par défaut est None."
#. Translators: Cluster status descriptions
#: django_q/conf.py:194
#: conf.py:202
msgid "Starting"
msgstr "Démarrage"
#: django_q/conf.py:195
#: conf.py:203
msgid "Working"
msgstr "Actif"
#: django_q/conf.py:196
#: conf.py:204
msgid "Idle"
msgstr "En attente"
#: django_q/conf.py:197
#: conf.py:205
msgid "Stopped"
msgstr "Arrêté"
#: django_q/conf.py:198
#: conf.py:206
msgid "Stopping"
msgstr "En cours darrêt"
#. Translators: help text for qcluster management command
#: django_q/management/commands/qcluster.py:9
#: management/commands/qcluster.py:9
msgid "Starts a Django Q Cluster."
msgstr "Démarre un cluster Django Q."
#. Translators: help text for qinfo management command
#: django_q/management/commands/qinfo.py:11
#: management/commands/qinfo.py:11
msgid "General information over all clusters."
msgstr "Informations générales sur tous les clusters."
#. Translators: help text for qmemory management command
#: django_q/management/commands/qmemory.py:9
#: management/commands/qmemory.py:9
#, fuzzy
#| msgid "Monitors Q Cluster activity"
msgid "Monitors Q Cluster memory usage"
msgstr "Surveille l'utilisation de la mémoire du cluster Q"
#. Translators: help text for qmonitor management command
#: django_q/management/commands/qmonitor.py:9
#: management/commands/qmonitor.py:9
msgid "Monitors Q Cluster activity"
msgstr "Activité du cluster Moniteur Q"
#: django_q/models.py:119
#: models.py:125
msgid "Successful task"
msgstr "Tâche réussie"
#: django_q/models.py:120
#: models.py:126
msgid "Successful tasks"
msgstr "Tâches réussies"
#: django_q/models.py:135
#: models.py:141
msgid "Failed task"
msgstr "Tâche échoué"
#: django_q/models.py:136
#: models.py:142
msgid "Failed tasks"
msgstr "Tâches échouées"
#: django_q/models.py:160
#: models.py:150 models.py:234
msgid "Please install croniter to enable cron expressions"
msgstr "Veuillez installer croniter pour activer les expressions croniques."
#: models.py:170
msgid "e.g. 1, 2, 'John'"
msgstr "ex. 1, 2, Jean"
#: django_q/models.py:162
#: models.py:172
msgid "e.g. x=1, y=2, name='John'"
msgstr "p. ex. x = 1, y = 2, Nom = Jean"
#: django_q/models.py:176
#: models.py:186
msgid "Once"
msgstr "Une fois"
#: django_q/models.py:177
#: models.py:187
msgid "Minutes"
msgstr "Minutes"
#: django_q/models.py:178
#: models.py:188
msgid "Hourly"
msgstr "Toutes les heures"
#: django_q/models.py:179
#: models.py:189
msgid "Daily"
msgstr "Quotidien"
#: django_q/models.py:180
#: models.py:190
msgid "Weekly"
msgstr "Hebdomadaire"
#: django_q/models.py:181
#: models.py:191
#, fuzzy
#| msgid "Weekly"
msgid "Biweekly"
msgstr "Bihebdomadaire"
#: django_q/models.py:182
#: models.py:192
msgid "Monthly"
msgstr "Mensuel"
#: django_q/models.py:183
#: models.py:193
#, fuzzy
#| msgid "Monthly"
msgid "Bimonthly"
msgstr "Bimestriel"
#: django_q/models.py:184
#: models.py:194
msgid "Quarterly"
msgstr "Tous les quart-dheure"
#: django_q/models.py:185
#: models.py:195
msgid "Yearly"
msgstr "Annuel"
#: django_q/models.py:186
#: models.py:196
msgid "Cron"
msgstr "Cron"
#: django_q/models.py:189
#: models.py:199
msgid "Schedule Type"
msgstr "Type de plannification"
#: django_q/models.py:192
#: models.py:202
msgid "Number of minutes for the Minutes type"
msgstr "Nombre de minutes pour le type de minutes"
#: django_q/models.py:195
#: models.py:205
msgid "Repeats"
msgstr "Répéter"
#: django_q/models.py:195
#: models.py:205
msgid "n = n times, -1 = forever"
msgstr "n = n fois,-1 = Toujours"
#: django_q/models.py:198
#: models.py:208
msgid "Next Run"
msgstr "Prochaine exécution"
#: django_q/models.py:205
#: models.py:215
msgid "Cron expression"
msgstr "Expression du Cron"
#: django_q/models.py:235
#: models.py:224
msgid "Name of kwarg to pass intended schedule date"
msgstr "Nom du kwarg pour passer la date d'éxecution prévue"
#: models.py:299
msgid "Scheduled task"
msgstr "Tâche planifiée"
#: django_q/models.py:236
#: models.py:300
msgid "Scheduled tasks"
msgstr "Tâches planifiées"
#: django_q/models.py:262
#: models.py:326
msgid "Queued task"
msgstr "Tâche en file d'attente"
#: django_q/models.py:263
#: models.py:327
msgid "Queued tasks"
msgstr "Tâches en file d'attente"
#: django_q/monitor.py:62 django_q/monitor.py:339
#: monitor.py:64 monitor.py:348
msgid "Host"
msgstr "Hôte"
#: django_q/monitor.py:66 django_q/monitor.py:343 django_q/monitor.py:450
#: monitor.py:68 monitor.py:352 monitor.py:459
msgid "Id"
msgstr "Id"
#: django_q/monitor.py:70
#: monitor.py:72
msgid "State"
msgstr "Statut"
#: django_q/monitor.py:74
#: monitor.py:76
msgid "Pool"
msgstr "Piscine"
#: django_q/monitor.py:78
#: monitor.py:80
msgid "TQ"
msgstr "TQ"
#: django_q/monitor.py:82
#: monitor.py:84
msgid "RQ"
msgstr "RQ"
#: django_q/monitor.py:86
#: monitor.py:88
msgid "RC"
msgstr "RC"
#: django_q/monitor.py:90
#: monitor.py:92
msgid "Up"
msgstr "Haut"
#: django_q/monitor.py:170 django_q/monitor.py:279
#: monitor.py:172 monitor.py:286
msgid "Queued"
msgstr "En file d'attente"
#: django_q/monitor.py:178
#: monitor.py:180
msgid "Success"
msgstr "Succès"
#: django_q/monitor.py:188 django_q/monitor.py:287
#: monitor.py:190 monitor.py:294
msgid "Failures"
msgstr "Défaillances"
#: django_q/monitor.py:199 django_q/monitor.py:485
#: monitor.py:201 monitor.py:498
msgid "[Press q to quit]"
msgstr "[appuyez sur q pour quitter]"
#: django_q/monitor.py:223
#: monitor.py:227
msgid "day"
msgstr "jour"
#: django_q/monitor.py:244
#: monitor.py:248
msgid "second"
msgstr "seconde"
#: django_q/monitor.py:247
#: monitor.py:251
msgid "minute"
msgstr "minute"
#: django_q/monitor.py:250
#: monitor.py:254
msgid "hour"
msgstr "heure"
#: django_q/monitor.py:260
#: monitor.py:263
#, python-format
msgid "-- %(prefix)s %(version)s on %(info)s --"
msgstr "--%(prefix)s %(version)s sur %(info)s --"
#: django_q/monitor.py:266
#: monitor.py:273
msgid "Clusters"
msgstr "Grappes"
#: django_q/monitor.py:270
#: monitor.py:277
msgid "Workers"
msgstr "Processus"
#: django_q/monitor.py:274
#: monitor.py:281
msgid "Restarts"
msgstr "Redémarrages"
#: django_q/monitor.py:283
#: monitor.py:290
msgid "Successes"
msgstr "Succès"
#: django_q/monitor.py:292
#: monitor.py:299
msgid "Schedules"
msgstr "Planifications"
#: django_q/monitor.py:296
#: monitor.py:303
#, python-format
msgid "Tasks/%(per)s"
msgstr "Tâches/%(per)s"
#: django_q/monitor.py:300
#: monitor.py:307
msgid "Avg time"
msgstr "Temps Moyen"
#: django_q/monitor.py:348
#: monitor.py:357
msgid "Available (%)"
msgstr ""
#: django_q/monitor.py:354
#: monitor.py:363
msgid "Available (MB)"
msgstr "Disponible sur (MB)"
#: django_q/monitor.py:359
#: monitor.py:368
msgid "Total (MB)"
msgstr "Total (MB)"
#: django_q/monitor.py:364
#: monitor.py:373
msgid "Sentinel (MB)"
msgstr "Sentinel (MB)"
#: django_q/monitor.py:370
#: monitor.py:379
msgid "Monitor (MB)"
msgstr "Monitor (MB)"
#: django_q/monitor.py:376
#: monitor.py:385
#, fuzzy
#| msgid "Workers"
msgid "Workers (MB)"
msgstr "Processus (MB)"
#: django_q/monitor.py:478
#: monitor.py:487
#, python-format
msgid "Available lowest (): %(memory_percent)s ((at)s)"
msgstr "Disponible le plus bas () : %(memory_percent)s ((at)s)"
#: django_q/monitor.py:496
#: monitor.py:509
msgid "No clusters appear to be running."
msgstr "Aucun cluster ne semble être en cours d'exécution."
#: django_q/signals.py:22
#: signals.py:22
#, python-format
msgid "malformed return hook '%(hook)s' for [%(name)s]"
msgstr "hook de retour mal formé' %(hook)s 'pour [%(name)s]"
#: django_q/signals.py:30
#: signals.py:30
#, python-format
msgid "return hook %(hook)s failed on [%(name)s] because %(error)s"
msgstr "le crochet de retour %(hook)s a échoué sur [%(name)s] parce que %(error)s"
msgstr ""
"le crochet de retour %(hook)s a échoué sur [%(name)s] parce que %(error)s"
#, python-format
#~ msgid ""
#~ "Could not process '%(func_name)s'. Check the location of the function and "
#~ "the args/kwargs."
#~ msgstr ""
#~ "Impossible de traiter '%(func_name)s'. Vérifiez l'emplacement de la "
#~ "fonction et les args/kwargs."

View File

@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-11-12 01:47+0000\n"
"POT-Creation-Date: 2023-01-15 23:35+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Ethem Güner <ethemguener@gmail.com>\n"
"Language-Team: \n"
@@ -18,172 +18,161 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#: django_q/admin.py:43
#: admin.py:43
msgid "Resubmit selected tasks to queue"
msgstr "Seçili işleri kuyruğa tekrar gönder"
#: django_q/admin.py:98 django_q/models.py:228
#: admin.py:107 models.py:293
#, fuzzy
#| msgid "Success"
msgid "success"
msgstr "başarılı olanlar"
#: django_q/admin.py:109 django_q/models.py:230
#: admin.py:119 models.py:295
msgid "last_run"
msgstr ""
#: django_q/cluster.py:77
#: cluster.py:76
#, python-format
msgid "Q Cluster %(name)s starting."
msgstr "Q Cluster %(name)s başlatılıyor."
#: django_q/cluster.py:85
#: cluster.py:84
#, python-format
msgid "Q Cluster %(name)s stopping."
msgstr "Q Cluster %(name)s durduruluyor."
#: django_q/cluster.py:88
#: cluster.py:87
#, python-format
msgid "Q Cluster %(name)s has stopped."
msgstr "Q Cluster %(name)s durduruldu."
#: django_q/cluster.py:96
#: cluster.py:94
#, python-format
msgid "%(name)s got signal %(signal)s"
msgstr "%(name)s, %(signal)s pid'inde izleniyor/monitoring yapılıyor."
#: django_q/cluster.py:219
#: cluster.py:221
#, python-format
msgid "reincarnated monitor %(name)s after sudden death"
msgstr "Monitor %(name)s ani ölüm sonrası tekrar dirildi"
#: django_q/cluster.py:222
#: cluster.py:227
#, python-format
msgid "reincarnated pusher %(name)s after sudden death"
msgstr "Pusher %(name)s ani ölüm sonrası tekrar dirildi"
#: django_q/cluster.py:229
#: cluster.py:238
#, python-format
msgid "reincarnated worker %(name)s after timeout"
msgstr "Worker %(name)s zaman aşımı sonrası tekrar dirildi"
#: django_q/cluster.py:231
#: cluster.py:242
#, python-format
msgid "recycled worker %(name)s"
msgstr "Worker %(name)s geri döndürüldü"
#: django_q/cluster.py:233
#: cluster.py:245
#, python-format
msgid "reincarnated worker %(name)s after death"
msgstr "Worker %(name)s ani ölüm sonrası tekrar dirildi"
#: django_q/cluster.py:256
#: cluster.py:269
#, python-format
msgid "%(name)s guarding cluster %(cluster_name)s"
msgstr "%(name)s, %(cluster_name)s cluster'ını koruyor"
#: django_q/cluster.py:261
#: cluster.py:278
#, python-format
msgid "Q Cluster %(cluster_name)s running."
msgstr "Q Cluster %(cluster_name)s başlatılıyor."
#: django_q/cluster.py:295
#: cluster.py:314
#, python-format
msgid "%(name)s stopping cluster processes"
msgstr "Cluster %(name)s işlemleri durduruluyor."
#: django_q/cluster.py:320
#: cluster.py:339
#, python-format
msgid "%(name)s waiting for the monitor."
msgstr "%(name)s monitor için bekliyor."
#: django_q/cluster.py:342
#: cluster.py:362
#, python-format
msgid "%(process_name)s pushing tasks at %(id)s"
msgstr "%(process_name)s, işleri %(id)s pid'ine gönderiyor."
#: django_q/cluster.py:363
#: cluster.py:386
#, python-format
msgid "queueing from %(list_key)s"
msgstr ""
#: django_q/cluster.py:366
#: cluster.py:390
#, python-format
msgid "%(name)s stopped pushing tasks"
msgstr "%(name)s işleri göndermeyi durdurdu"
#: django_q/cluster.py:378
#: cluster.py:403
#, python-format
msgid "%(name)s monitoring at %(id)s"
msgstr "%(name)s, %(id)s pid'inde izleniyor/monitoring yapılıyor."
#: django_q/cluster.py:395
#: cluster.py:422
#, python-format
msgid "Processed '%(info_name)s' (%(task_name)s)"
msgstr "[%(task_name)s] - '%(info_name)s işlendi."
#: django_q/cluster.py:398
#: cluster.py:428
#, python-format
msgid "Failed '%(info_name)s' (%(task_name)s) - %(task_result)s"
msgstr "[%(task_name)s] - '%(info_name)s' - %(task_result)s başarısız oldu"
#: django_q/cluster.py:399
#: cluster.py:435
#, python-format
msgid "%(name)s stopped monitoring results"
msgstr "%(name)s sonuçları göstermeyi bıraktı"
#: django_q/cluster.py:413
#: cluster.py:451
#, python-format
msgid "%(proc_name)s ready for work at %(id)s"
msgstr "%(proc_name)s, %(id)s pid'inde çalışmaya hazır"
#: django_q/cluster.py:425
#: cluster.py:466
#, python-format
msgid "%(proc_name)s processing '%(func_name)s' (%(task_name)s)"
msgstr "%(proc_name)s, '%(func_name)s' [%(task_name)s] işlerini işiyor"
#: django_q/cluster.py:440
#, python-format
msgid ""
"Could not process '%(func_name)s'. Check the location of the function and "
"the args/kwargs."
msgstr ""
"%(func_name)s' işlenemedi. İşlevin konumunu ve args/kwargs öğelerini kontrol "
"edin."
#: django_q/cluster.py:456
#: cluster.py:507
#, python-format
msgid "%(proc_name)s stopped doing work"
msgstr "%(proc_name)s çalışmayı bıraktı"
#: django_q/cluster.py:649 django_q/models.py:144
msgid "Please install croniter to enable cron expressions"
msgstr "Cron expressions'ları açmak için croniter yükleyin"
#: django_q/cluster.py:672
#: cluster.py:712
#, python-format
msgid "%(process_name)s failed to create a task from schedule [%(schedule)s]"
msgstr "%(process_name)s programdan bir görev oluşturamadı [%(schedule)s]"
#: django_q/cluster.py:678
#, python-format
msgid "%(process_name)s created a task from schedule [%(schedule)s]"
#: cluster.py:723
#, fuzzy, python-format
#| msgid "%(process_name)s created a task from schedule [%(schedule)s]"
msgid ""
"%(process_name)s created task %(task_name)s from schedule [%(schedule)s]"
msgstr "%(process_name)s programdan bir görev oluşturamadı [%(schedule)s]"
#: django_q/cluster.py:718
#: cluster.py:769
msgid "Skipping cpu affinity because psutil was not found."
msgstr "Psutil bulunamadığı için cpu benzeşimi atlanıyor."
#: django_q/cluster.py:723
#: cluster.py:774
msgid "Faking cpu affinity because it is not supported on this platform"
msgstr "Bu platformda desteklenmediği için sahte cpu benzeşimi"
#: django_q/cluster.py:744
#: cluster.py:796
#, python-format
msgid "%(pid)s will use cpu %(affinity)s"
msgstr "%(pid)s cpu %(affinity)s kullanacaktır"
#: django_q/conf.py:85
#: conf.py:85
#, python-format
msgid ""
"SAVE_LIMIT_PER (%(option)s) is not a valid option. Options are: 'group', "
@@ -193,295 +182,311 @@ msgstr ""
"'group', 'name', 'func' ve None. Varsayılan değer None'dır."
#. Translators: Cluster status descriptions
#: django_q/conf.py:194
#: conf.py:202
msgid "Starting"
msgstr "Başlıyor"
#: django_q/conf.py:195
#: conf.py:203
msgid "Working"
msgstr "Çalışıyor"
#: django_q/conf.py:196
#: conf.py:204
msgid "Idle"
msgstr "Boşta"
#: django_q/conf.py:197
#: conf.py:205
msgid "Stopped"
msgstr "Durdu"
#: django_q/conf.py:198
#: conf.py:206
msgid "Stopping"
msgstr "Durduruluyor"
#. Translators: help text for qcluster management command
#: django_q/management/commands/qcluster.py:9
#: management/commands/qcluster.py:9
msgid "Starts a Django Q Cluster."
msgstr "Bir Django Q Cluster çalıştırır."
#. Translators: help text for qinfo management command
#: django_q/management/commands/qinfo.py:11
#: management/commands/qinfo.py:11
msgid "General information over all clusters."
msgstr "Tüm cluster'lar için genel bilgiler."
#. Translators: help text for qmemory management command
#: django_q/management/commands/qmemory.py:9
#: management/commands/qmemory.py:9
msgid "Monitors Q Cluster memory usage"
msgstr "Q Cluster'ın bellek kullanımını izler"
#. Translators: help text for qmonitor management command
#: django_q/management/commands/qmonitor.py:9
#: management/commands/qmonitor.py:9
msgid "Monitors Q Cluster activity"
msgstr "Q Cluster'ın aktivitelerini izler"
#: django_q/models.py:119
#: models.py:125
msgid "Successful task"
msgstr "Başarılı iş"
#: django_q/models.py:120
#: models.py:126
msgid "Successful tasks"
msgstr "Başarılı işler"
#: django_q/models.py:135
#: models.py:141
msgid "Failed task"
msgstr "Başarısız iş"
#: django_q/models.py:136
#: models.py:142
msgid "Failed tasks"
msgstr "Başarısız işler"
#: django_q/models.py:160
#: models.py:150 models.py:234
msgid "Please install croniter to enable cron expressions"
msgstr "Cron expressions'ları açmak için croniter yükleyin"
#: models.py:170
msgid "e.g. 1, 2, 'John'"
msgstr "Örneğin: 1, 2, 'Melih'"
#: django_q/models.py:162
#: models.py:172
msgid "e.g. x=1, y=2, name='John'"
msgstr "Örneğin: x=1, y=2, name='Melih'"
#: django_q/models.py:176
#: models.py:186
msgid "Once"
msgstr "Bir kere"
#: django_q/models.py:177
#: models.py:187
msgid "Minutes"
msgstr "Dakika"
#: django_q/models.py:178
#: models.py:188
msgid "Hourly"
msgstr "Saatlik"
#: django_q/models.py:179
#: models.py:189
msgid "Daily"
msgstr "Günlük"
#: django_q/models.py:180
#: models.py:190
msgid "Weekly"
msgstr "Haftalık"
#: django_q/models.py:181
#: models.py:191
#, fuzzy
#| msgid "Weekly"
msgid "Biweekly"
msgstr "İki haftada bir"
#: django_q/models.py:182
#: models.py:192
msgid "Monthly"
msgstr "Aylık"
#: django_q/models.py:183
#: models.py:193
#, fuzzy
#| msgid "Monthly"
msgid "Bimonthly"
msgstr "İki ayda bir"
#: django_q/models.py:184
#: models.py:194
msgid "Quarterly"
msgstr "Bir Çeyrek (3 Ay)"
#: django_q/models.py:185
#: models.py:195
msgid "Yearly"
msgstr "Yıllık"
#: django_q/models.py:186
#: models.py:196
msgid "Cron"
msgstr ""
#: django_q/models.py:189
#: models.py:199
msgid "Schedule Type"
msgstr "Zamanlama Tipi"
#: django_q/models.py:192
#: models.py:202
msgid "Number of minutes for the Minutes type"
msgstr "Dakika tipine göre dakika sayısı"
#: django_q/models.py:195
#: models.py:205
msgid "Repeats"
msgstr "Tekrar eder"
#: django_q/models.py:195
#: models.py:205
msgid "n = n times, -1 = forever"
msgstr "n = n kere, -1 = sonsuza kadar"
#: django_q/models.py:198
#: models.py:208
msgid "Next Run"
msgstr "Bir dahaki çalışma tarihi"
#: django_q/models.py:205
#: models.py:215
msgid "Cron expression"
msgstr ""
#: django_q/models.py:235
#: models.py:224
msgid "Name of kwarg to pass intended schedule date"
msgstr ""
#: models.py:299
msgid "Scheduled task"
msgstr "Zamanlanmış iş"
#: django_q/models.py:236
#: models.py:300
msgid "Scheduled tasks"
msgstr "Zamanlanmış işler"
#: django_q/models.py:262
#: models.py:326
msgid "Queued task"
msgstr "Sıraya alınmış iş"
#: django_q/models.py:263
#: models.py:327
msgid "Queued tasks"
msgstr "Sıraya alınmış işler"
#: django_q/monitor.py:62 django_q/monitor.py:339
#: monitor.py:64 monitor.py:348
msgid "Host"
msgstr ""
#: django_q/monitor.py:66 django_q/monitor.py:343 django_q/monitor.py:450
#: monitor.py:68 monitor.py:352 monitor.py:459
msgid "Id"
msgstr ""
#: django_q/monitor.py:70
#: monitor.py:72
msgid "State"
msgstr "Durum"
#: django_q/monitor.py:74
#: monitor.py:76
msgid "Pool"
msgstr "Havuz"
#: django_q/monitor.py:78
#: monitor.py:80
msgid "TQ"
msgstr ""
#: django_q/monitor.py:82
#: monitor.py:84
msgid "RQ"
msgstr ""
#: django_q/monitor.py:86
#: monitor.py:88
msgid "RC"
msgstr ""
#: django_q/monitor.py:90
#: monitor.py:92
msgid "Up"
msgstr ""
#: django_q/monitor.py:170 django_q/monitor.py:279
#: monitor.py:172 monitor.py:286
msgid "Queued"
msgstr "Sıraya alınmış"
#: django_q/monitor.py:178
#: monitor.py:180
msgid "Success"
msgstr "Başarılı olanlar"
#: django_q/monitor.py:188 django_q/monitor.py:287
#: monitor.py:190 monitor.py:294
msgid "Failures"
msgstr "Başarısız olanlar"
#: django_q/monitor.py:199 django_q/monitor.py:485
#: monitor.py:201 monitor.py:498
msgid "[Press q to quit]"
msgstr "[Çıkmak için q'ya basın]"
#: django_q/monitor.py:223
#: monitor.py:227
msgid "day"
msgstr "gün"
#: django_q/monitor.py:244
#: monitor.py:248
msgid "second"
msgstr "saniye"
#: django_q/monitor.py:247
#: monitor.py:251
msgid "minute"
msgstr "dakika"
#: django_q/monitor.py:250
#: monitor.py:254
msgid "hour"
msgstr "saat"
#: django_q/monitor.py:260
#: monitor.py:263
#, python-format
msgid "-- %(prefix)s %(version)s on %(info)s --"
msgstr "-- %(prefix)s %(version)s üzerinde %(info)s --"
#: django_q/monitor.py:266
#: monitor.py:273
msgid "Clusters"
msgstr ""
#: django_q/monitor.py:270
#: monitor.py:277
msgid "Workers"
msgstr ""
#: django_q/monitor.py:274
#: monitor.py:281
msgid "Restarts"
msgstr "Yeniden çalıştırmalar"
#: django_q/monitor.py:283
#: monitor.py:290
msgid "Successes"
msgstr "Başarılı olanlar"
#: django_q/monitor.py:292
#: monitor.py:299
msgid "Schedules"
msgstr "Zamanlanmışlar"
#: django_q/monitor.py:296
#: monitor.py:303
#, python-format
msgid "Tasks/%(per)s"
msgstr "İş/%(per)s"
#: django_q/monitor.py:300
#: monitor.py:307
msgid "Avg time"
msgstr "Ortalama süre"
#: django_q/monitor.py:348
#: monitor.py:357
msgid "Available (%)"
msgstr "Müsait (%) "
#: django_q/monitor.py:354
#: monitor.py:363
msgid "Available (MB)"
msgstr "Müsait (MB)"
#: django_q/monitor.py:359
#: monitor.py:368
msgid "Total (MB)"
msgstr "Toplam (MB)"
#: django_q/monitor.py:364
#: monitor.py:373
msgid "Sentinel (MB)"
msgstr ""
#: django_q/monitor.py:370
#: monitor.py:379
msgid "Monitor (MB)"
msgstr "İzleme (MB)"
#: django_q/monitor.py:376
#: monitor.py:385
msgid "Workers (MB)"
msgstr ""
#: django_q/monitor.py:478
#: monitor.py:487
#, python-format
msgid "Available lowest (): %(memory_percent)s ((at)s)"
msgstr "Mevcut en düşük (): %(memory_percent)s ((at)s)"
#: django_q/monitor.py:496
#: monitor.py:509
msgid "No clusters appear to be running."
msgstr "Hiçbir küme çalışıyor görünmüyor."
#: django_q/signals.py:22
#: signals.py:22
#, python-format
msgid "malformed return hook '%(hook)s' for [%(name)s]"
msgstr ""
#: django_q/signals.py:30
#: signals.py:30
#, python-format
msgid "return hook %(hook)s failed on [%(name)s] because %(error)s"
msgstr ""
#, python-format
#~ msgid ""
#~ "Could not process '%(func_name)s'. Check the location of the function and "
#~ "the args/kwargs."
#~ msgstr ""
#~ "%(func_name)s' işlenemedi. İşlevin konumunu ve args/kwargs öğelerini "
#~ "kontrol edin."

View File

@@ -0,0 +1,25 @@
# Generated by Django 4.1.2 on 2023-01-15 22:34
from django.db import migrations, models
import django_q.models
class Migration(migrations.Migration):
dependencies = [
("django_q", "0015_alter_schedule_schedule_type"),
]
operations = [
migrations.AddField(
model_name="schedule",
name="intended_date_kwarg",
field=models.CharField(
blank=True,
help_text="Name of kwarg to pass intended schedule date",
max_length=100,
null=True,
validators=[django_q.models.validate_kwarg],
),
),
]

View File

@@ -1,4 +1,5 @@
from datetime import datetime, timedelta
from keyword import iskeyword
# Django
from django import get_version
@@ -153,6 +154,10 @@ def validate_cron(value):
raise ValidationError(e)
def validate_kwarg(value):
return value.isidentifier() and not iskeyword(value)
class Schedule(models.Model):
name = models.CharField(max_length=100, null=True, blank=True)
func = models.CharField(max_length=256, help_text="e.g. module.tasks.function")
@@ -211,6 +216,13 @@ class Schedule(models.Model):
)
task = models.CharField(max_length=100, null=True, editable=False)
cluster = models.CharField(max_length=100, default=None, null=True, blank=True)
intended_date_kwarg = models.CharField(
max_length=100,
null=True,
blank=True,
validators=[validate_kwarg],
help_text=_("Name of kwarg to pass intended schedule date"),
)
def calculate_next_run(self, next_run=None):
# next run is always in UTC

View File

@@ -90,6 +90,7 @@ def schedule(func, *args, **kwargs):
:type next_run: datetime.datetime
:param cluster: optional cluster name.
:param cron: optional cron expression
:param intended_date_kwarg: optional identifier to pass intended schedule date.
:param kwargs: function keyword arguments.
:return: the schedule object.
:rtype: Schedule
@@ -102,6 +103,7 @@ def schedule(func, *args, **kwargs):
next_run = kwargs.pop("next_run", timezone.now())
cron = kwargs.pop("cron", None)
cluster = kwargs.pop("cluster", None)
intended_date_kwarg = kwargs.pop("intended_date_kwarg", None)
# check for name duplicates instead of am unique constraint
if name and Schedule.objects.filter(name=name).exists():
@@ -120,6 +122,7 @@ def schedule(func, *args, **kwargs):
next_run=next_run,
cron=cron,
cluster=cluster,
intended_date_kwarg=intended_date_kwarg,
)
# make sure we trigger validation
s.full_clean()

View File

@@ -417,6 +417,38 @@ def test_scheduler(broker, monkeypatch):
assert task_queue.qsize() == 1
@pytest.mark.django_db
def test_intended_schedule_kwarg(broker, monkeypatch):
broker.list_key = "scheduler_test:q"
broker.delete_queue()
run_date = timezone.now()-timedelta(hours=1)
schedule = create_schedule(
"math.copysign",
1,
-1,
name="test math",
hook="django_q.tests.tasks.result",
schedule_type=Schedule.HOURLY,
repeats=1,
next_run=run_date,
intended_date_kwarg='intended_date',
)
assert schedule.last_run() is None
assert schedule.intended_date_kwarg == 'intended_date'
# run scheduler
scheduler(broker=broker)
# set up the workflow
task_queue = Queue()
stop_event = Event()
stop_event.set()
# push it
pusher(task_queue, stop_event, broker=broker)
assert task_queue.qsize() == 1
task = task_queue.get()
assert 'intended_date' in task['kwargs']
assert task['kwargs']['intended_date'] == run_date.isoformat()
@override_settings(
DATABASE_ROUTERS=REPLICA_DATABASE_ROUTERS, DATABASES=REPLICA_DATABASES
)