Skip to main content
Archived

This project has been archived by its maintainers, and is no longer receiving any updates.

a-task-queue

Easily create and run tasks (=function calls) with almost seamless transition between Local development and Distributed deployment."

Usage

from ataskq import TaskQ, Task, targs
from ataskq.tasks_utils import hello_world, dummy_args_task


def hello_world():
    print("hello world")


def task_with_args(*args, **kwargs):
    print(f"task_with_args args: {args}, kwargs: {kwargs}")


# create  job
tr = TaskQ().create_job()

# add tasks
# add tasks (functions to run)
tr.add_tasks(
    [
        Task(entrypoint=hello_world),
        Task(entrypoint=task_with_args, targs=targs("arg0", "arg1", kwarg1=10, kwarg2="this is kwarg2")),
    ]
)

# run the tasks
tr.run()  # to run in parallel add concurrency=N

more example can be found here

Contributer

to setup project run

./contrib/setup.sh

vs code

to get nominal vscode settings run

./contrib/.vscode/init.sh

Release files for ataskq 0.6.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ataskq 0.6.5
File Size Uploaded
ataskq-0.6.5.tar.gz 64.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ataskq 0.6.5
File Interpreter ABI Platform
ataskq-0.6.5-py3-none-any.whl Python 3 none any Details

Total release size: 140.7 kB

Release files / ataskq-0.6.5.tar.gz

Download URL ataskq-0.6.5.tar.gz
Size 64.5 kB
Tags Source
SHA-256 checksum
How to use checksums
3d779245c00fb4bee524b4db0adcb2fd0f346a3ecce66654df6529e95ed0906c
BLAKE2b-256 checksum
How to use checksums
8e8e83d2a8a1ff2385ffcf9d99d44b89890f98749396fd6961fc4f9fb7aa1c2e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.12.4

Release files / ataskq-0.6.5-py3-none-any.whl

Download URL ataskq-0.6.5-py3-none-any.whl
Size 76.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f7da88ea902dab1ce63e150ae3485fc9a2308224597874ebec909813dfe5b77d
BLAKE2b-256 checksum
How to use checksums
afade77a87325b2327fcb1f378f3926befca28ea5b7c640dcf567728757a575c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.0 CPython/3.12.4
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page