dramatiq-abort-1.1.0
توضیحات
Dramatiq middleware to abort tasks.
| ویژگی | مقدار |
|---|---|
| سیستم عامل | - |
| نام فایل | dramatiq-abort-1.1.0 |
| نام | dramatiq-abort |
| نسخه کتابخانه | 1.1.0 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | Flare Systems Inc. |
| ایمیل نویسنده | oss@flare.systems |
| آدرس صفحه اصلی | https://github.com/flared/dramatiq-abort |
| آدرس اینترنتی | https://pypi.org/project/dramatiq-abort/ |
| مجوز | - |
# dramatiq-abort
Add the aborting feature to [dramatiq] through a simple middleware with flexible backend.
Current version support aborting using the [Redis] store.
[](https://github.com/Flared/dramatiq-abort/actions?query=workflow%3A%22Push%22)
[](https://badge.fury.io/py/dramatiq-abort)
[](http://flared.github.io/dramatiq-abort)
## Installation
Since the only available backend right now is [Redis]:
pip install dramatiq_abort[redis]
**Documentation**: http://flared.github.io/dramatiq-abort
## Quickstart
```python
from dramatiq import get_broker
from dramatiq_abort import Abortable, backends, abort
abortable = Abortable(backend=backends.RedisBackend())
get_broker().add_middleware(abortable)
# ...
import dramatiq
@dramatiq.actor
def my_long_running_task(): ...
message = my_long_running_task.send()
# Now abort the message.
abort(message.message_id)
```
[Redis]: https://redis.io
[dramatiq]: https://dramatiq.io/
نیازمندی
| مقدار | نام |
|---|---|
| - | dramatiq |
| >=1.1 | gevent |
| <5.0,>=2.0 | redis |
| >=1.1 | gevent |
| <5.0,>=2.0 | redis |
| - | flake8 |
| - | flake8-bugbear |
| - | flake8-quotes |
| - | isort |
| - | mypy |
| - | types-redis |
| - | black |
| - | pytest |
| - | pytest-cov |
| >=3.14.0 | tox |
| - | sphinx |
| - | sphinx-autodoc-typehints |
| - | build |
| - | wheel |
| - | twine |
| >=1.1 | gevent |
| <5.0,>=2.0 | redis |
نحوه نصب
نصب پکیج whl dramatiq-abort-1.1.0:
pip install dramatiq-abort-1.1.0.whl
نصب پکیج tar.gz dramatiq-abort-1.1.0:
pip install dramatiq-abort-1.1.0.tar.gz