Skip to main content

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.4.tar.gz (4.6 kB view details)

Uploaded Source

Built Distribution

pseudo_cron-1.0.4-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file pseudo_cron-1.0.4.tar.gz.

File metadata

  • Download URL: pseudo_cron-1.0.4.tar.gz
  • Upload date:
  • Size: 4.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12

File hashes

Hashes for pseudo_cron-1.0.4.tar.gz
Algorithm Hash digest
SHA256 74c669ffbfa97f01e21b7ffa219d4df6998353febcd16fa1eeea52211d70016e
MD5 0a93086a7f110bd8579084fe9c5d0a1c
BLAKE2b-256 dbfcde6e95b0e85453f48cb814822884eb376a02fad32daf45f06046f68f6337

See more details on using hashes here.

File details

Details for the file pseudo_cron-1.0.4-py3-none-any.whl.

File metadata

  • Download URL: pseudo_cron-1.0.4-py3-none-any.whl
  • Upload date:
  • Size: 6.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.57.0 urllib3/1.26.5 CPython/3.10.12

File hashes

Hashes for pseudo_cron-1.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 5fff3315a064ac09602ba82776b1b6a308f34747b5f175a0c244135c29a888b4
MD5 493dfee029f59cbcef429863acd9bb45
BLAKE2b-256 436cb9260f706518cc4d68f27dafd7add174f1b59158f80b8486c1fb2053eaf6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page