Pseudo cron for Django
Project description
pseudo-cron
Pseudo Cron Middleware for Django
Rationale
Schedule tasks for periodic execution without crontab.
Support
Supports: Python 3.9.
Supports Django Versions: 3.2.23
Installation
$ pip install pseudo_cron
Usage
Add pseudo_cron
to INSTALLED_APPS
.
Run migrations:
python manage.py migrate
Add the middleware:
MIDDLEWARE = [
...,
'pseudo_cron.middleware.CronMiddleware'
]
Add a cron.py
module to your app and schedule your periodic task:
from pseudo_cron.decorators import schedule_job
@schedule_job(24 * 60 * 60) # Run every 24 hrs
def my_task():
...
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pseudo_cron-1.0.3.tar.gz
(4.8 kB
view hashes)
Built Distribution
Close
Hashes for pseudo_cron-1.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d3694fb008b887fb2513e7363251ed96a646733736c3f8e4a1c3f89fcf74e036 |
|
MD5 | a9442ff15611f67aaa7be148049a6ba3 |
|
BLAKE2b-256 | 3a804827bd2fccfcead36b3310048bb5159e390ae9063c87f86960ef2ef172be |