Skip to main content

Lightweight task progress tracking with pluggable storage backends

Project description

progressorx

progressor — lightweight progress-tracking package for long-running tasks.

Features:

  • report_progress(task_id, progress=None, increase=None) — set or increment progress (0..100).
  • get_progress(task_id) — get current progress and status.
  • Pluggable backends: InMemory, Redis, SQLAlchemy (SQLite/Postgres).
  • Thread/process/distributed safe when using a proper backend (Redis/SQL).

Quick example

from progressorx import ProgressManager
from progressorx.backends.memory import InMemoryStore

store = InMemoryStore()
mgr = ProgressManager(store)

# create task
mgr.create('task-1')

# set and increment progress
mgr.report_progress('task-1', progress=10)
mgr.report_progress('task-1', increase=5)

rec = mgr.get_progress('task-1')
print(rec.task_id, rec.progress, rec.status)  # task-1 15.0 in_progress

Examples

  • Basic runnable example: src/progressorx/examples/basic.py
    • Run: python -m progressorx.examples.basic
  • FastAPI integration: src/progressorx/examples/fastapi.py
    • Run: uvicorn progressorx.examples.fastapi:app --reload

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

progressorx-0.0.7.tar.gz (43.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

progressorx-0.0.7-py3-none-any.whl (7.8 kB view details)

Uploaded Python 3

File details

Details for the file progressorx-0.0.7.tar.gz.

File metadata

  • Download URL: progressorx-0.0.7.tar.gz
  • Upload date:
  • Size: 43.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for progressorx-0.0.7.tar.gz
Algorithm Hash digest
SHA256 59a596adb3d9bf898bc22f7ce16c72912f1f8757c2b2aca71f45e9faf37ef90a
MD5 79ccf8433b6c0b789a524dc85da6de36
BLAKE2b-256 1ce36ad95f880f16236ab4e89847484af57b6f2c53894fa37de96d2119d6e553

See more details on using hashes here.

File details

Details for the file progressorx-0.0.7-py3-none-any.whl.

File metadata

  • Download URL: progressorx-0.0.7-py3-none-any.whl
  • Upload date:
  • Size: 7.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for progressorx-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 9f7b946412446fac980d943e5b74325ad50b7014c699d70078f91b1b20915aa2
MD5 3a0749cb4a7b9e5b26f2274b73edd0bd
BLAKE2b-256 b19f5974ac1c217579728f6f50d56562995fb5f590e9456c901e20ef8c3e2e1d

See more details on using hashes here.

Supported by

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