vercel-dramatiq
Dramatiq broker backed by Vercel Queue Service.
# tasks.py
import dramatiq
from vercel.integrations.dramatiq import VercelQueueBroker
broker = VercelQueueBroker()
dramatiq.set_broker(broker)
@dramatiq.actor
def send_email(user_id: str) -> None: ...
Constructing the broker explicitly is the recommended pattern: it always takes effect and the broker options are visible at the construction site. To store actor results in Vercel Runtime Cache, add the results middleware:
from dramatiq.results import Results
from vercel.integrations.dramatiq import VercelRuntimeCacheBackend
broker.add_middleware(Results(backend=VercelRuntimeCacheBackend()))
Alternatively, install_vercel_dramatiq_integration() sets Dramatiq's global
broker to a default VercelQueueBroker with the results middleware when no
broker has been configured yet. Note that this is a no-op once a global broker
exists, so broker options passed to the installer do not apply in environments
that install the integration first (Vercel functions do).
The broker uses push delivery when VERCEL is truthy in the environment and
poll delivery otherwise. Pass poll=False or poll=True to
VercelQueueBroker(...) to force a mode.
For Vercel push delivery, declare a module that exposes the broker as a queue
subscriber in pyproject.toml:
# worker.py
# Importing tasks declares the actors' queues on the broker.
from tasks import broker
__all__ = ["broker"]
[[tool.vercel.subscribers]]
entrypoint = "worker:broker"
The Vercel build introspects every queue declared on the broker and compiles
the subscriber into a queue-triggered function. That includes each queue's
Dramatiq delay queue: the default queue maps to both the default topic and
the sanitized default_DDQ delay topic, and retries and delayed messages are
delivered through the delay queue topic.
Set VERCEL_DRAMATIQ_DEBUG=1 to enable debug logging for the integration and
Dramatiq worker loggers.
The package is standalone and depends on vercel-queue and Dramatiq.
Metadata
Release files for vercel-dramatiq 0.7.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| vercel_dramatiq-0.7.9.tar.gz | 8.8 kB | Without provenance | Details for vercel_dramatiq-0.7.9.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| vercel_dramatiq-0.7.9-py3-none-any.whl | Python 3 | none | any | Details for vercel_dramatiq-0.7.9-py3-none-any.whl |
Total release size: 18.8 kB
Release files / vercel_dramatiq-0.7.9.tar.gz
| Download URL | vercel_dramatiq-0.7.9.tar.gz |
|---|---|
| Size | 8.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6720b956d493978c036054a2ef5580cea6555b432a2560165e98883a4d1d0d76
|
|
BLAKE2b-256 checksum How to use checksums |
803430ed18b804bdde241effb6c7ea03d44be3514255ec3125151ed39b25ca27
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.5 {"installer":{"name":"uv","version":"0.13.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / vercel_dramatiq-0.7.9-py3-none-any.whl
| Download URL | vercel_dramatiq-0.7.9-py3-none-any.whl |
|---|---|
| Size | 10.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3327ecb027d99706fc0dc7e82fdc5f46afb38b8ae4a884aa13e230a1a9074b8d
|
|
BLAKE2b-256 checksum How to use checksums |
115b269421c88ca24fea91d86d953450d443773e02d844d32fd24c5724a645d8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.5 {"installer":{"name":"uv","version":"0.13.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for vercel-dramatiq 0.7.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.