A powerful, yet straightforward library for managing and processing tasks concurrently.
Project description
ConcurrentTasking
ConcurrentTasking is a powerful, yet straightforward Python library for managing and processing tasks concurrently. Leveraging Python's asyncio library, it simplifies the queuing and asynchronous execution of tasks, providing real-time updates on their progress and outcomes.
Features
- Efficient management of a task queue for concurrent processing.
- Asynchronous execution of tasks with live updates on their status.
- Supports any callable Python function for flexible task creation.
- Detailed tracking of task statuses, from queued to completed or failed.
Installation
Install ConcurrentTasking using pip:
pip install ConcurrentTasking
Quick Start
Here's how to get up and running with ConcurrentTasking:
- Define a Task
from concurrent_tasks.models import Task
# Define an asynchronous function for your task
async def sample_task_function(arg1, arg2):
# Task logic here
return arg1 + arg2
# Create a task instance
task = Task(task_id="1", function=sample_task_function, args=[10, 20])
- Initialize the Task Manager and Add Tasks
from concurrent_tasks.task_manager import TaskManager
manager = TaskManager()
# Queue tasks for processing
await manager.add_task(task)
- Start Task Processing
# Begin processing queued tasks
await manager.process_tasks()
Contributing
Your contributions make ConcurrentTasking even better! Whether it's a feature request, bug report, or a pull request, we warmly welcome your input. Please feel free to open an issue or submit a PR.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ConcurrentTasking-0.1.0.tar.gz.
File metadata
- Download URL: ConcurrentTasking-0.1.0.tar.gz
- Upload date:
- Size: 5.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
44af80985b079fdf25c043ef5b54b3caa2dab46acaa2d7cfa3b5c515d9cbfec7
|
|
| MD5 |
4e9801e33c36290c9c6851bf7debeed2
|
|
| BLAKE2b-256 |
b8c20357e32d9b11e9aaff8af8a8c0f075738f029ec60d4b5bab4360fc6372a4
|
File details
Details for the file ConcurrentTasking-0.1.0-py3-none-any.whl.
File metadata
- Download URL: ConcurrentTasking-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f4405c21c315f39a7ad84f2ed1e0f359b7cb72555eb94b39226a7491dc3c2db8
|
|
| MD5 |
49721269bd6931ff8093bee1310d82c2
|
|
| BLAKE2b-256 |
e5eae2a2dceeeee6ca11ecd85ea23af6e30b686b0abc47b1e412b7ad5b2da81b
|