Skip to main content

honker (Python)

Python binding for Honker: durable queues, streams, pub/sub, and time-trigger scheduling on SQLite.

Full docs live in the main repo and docs site:

Install

pip install honker

The Python wheel includes Honker's SQLite loadable extension when the package is built through the release/proof workflow. To load Honker into your own sqlite3 or ORM connection:

import honker
import sqlite3

conn = sqlite3.connect("app.db")
honker.load_extension(conn)
conn.execute("SELECT honker_bootstrap()")

If a client needs the raw pieces instead, use extension_info():

path, entrypoint = honker.extension_info()

For local source builds, build and copy the extension before building the wheel:

git clone https://github.com/russellromney/honker
cd honker
cargo build --release -p honker-extension
scripts/copy-python-extension.sh

Quick start

import honker

db = honker.open("app.db")
q = db.queue("emails")

q.enqueue({"to": "alice@example.com"})

async for job in q.claim("worker-1"):
    send_email(job.payload)
    job.ack()

Delayed jobs use run_at:

import time

q.enqueue({"to": "later@example.com"}, run_at=int(time.time()) + 10)

Recurring schedules are registered on a Scheduler. Build the schedule with crontab(expr) or every_s(n), then run the scheduler loop (it enqueues onto the target queue on each boundary; a normal worker claims the jobs):

from honker import Scheduler, crontab, every_s

sched = Scheduler(db)
sched.add(name="fast", queue="emails", schedule=every_s(1), payload={"kind": "tick"})
sched.add(name="nightly", queue="emails", schedule=crontab("0 3 * * *"))

await sched.run()  # acquires the leader lock and fires due tasks

add() is keyword-only and schedule must be a CronSchedule (from crontab or every_s), not a raw string. Supported schedule expressions:

  • 5-field cron: crontab("0 3 * * *")
  • 6-field cron: crontab("*/2 * * * * *")
  • interval: every_s(1) (use every_s, not crontab("@every …"))

Notes

  • claim() wakes on database updates and on due deadlines like run_at.
  • schedule is the canonical recurring-schedule name.
  • cron still works as a compatibility alias in older call sites.
  • Construct db.queue(name) handles outside an open db.transaction(). First open for a name runs schema init in its own write transaction; doing that inside an outer transaction() raises RuntimeError (would otherwise deadlock the single writer). Create the handle first, then pass tx= to enqueue.

For streams, notify/listen, tasks, SQL extension usage, and full scheduler docs, see the main repo and docs site.

Metadata

Release files for honker 0.5.0

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

Built distributions (wheels)

Table of built distributions (wheels) for honker 0.5.0
File Actions
honker-0.5.0-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details for honker-0.5.0-cp311-abi3-win_amd64.whl
honker-0.5.0-cp311-abi3-manylinux_2_38_x86_64.whl CPython 3.11 abi3 Linux glibc 2.38+ x86-64 Details for honker-0.5.0-cp311-abi3-manylinux_2_38_x86_64.whl
honker-0.5.0-cp311-abi3-manylinux_2_38_aarch64.whl CPython 3.11 abi3 Linux glibc 2.38+ ARM64 Details for honker-0.5.0-cp311-abi3-manylinux_2_38_aarch64.whl
honker-0.5.0-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details for honker-0.5.0-cp311-abi3-macosx_11_0_arm64.whl
honker-0.5.0-cp311-abi3-macosx_10_12_x86_64.whl CPython 3.11 abi3 macOS 10.12+ x86-64 Details for honker-0.5.0-cp311-abi3-macosx_10_12_x86_64.whl

Total release size: 7.4 MB

Release files / honker-0.5.0-cp311-abi3-win_amd64.whl

Download URL honker-0.5.0-cp311-abi3-win_amd64.whl
Size 1.7 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
62e78378b4212ad9c04a4dd51b5ca57ff3d4e259271170a88745db60c3179602
BLAKE2b-256 checksum
How to use checksums
49b62ad40cfe8d35ca733ad51fb1334de03a71e1dc000826331e12f67f77485f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Release files / honker-0.5.0-cp311-abi3-manylinux_2_38_x86_64.whl

Download URL honker-0.5.0-cp311-abi3-manylinux_2_38_x86_64.whl
Size 1.9 MB
Tags CPython 3.11 Linux glibc 2.38+ x86-64 abi3
SHA-256 checksum
How to use checksums
c61cc173db699f5fbbc09f1821069416e8874075e16ee571d76c75a7be96e37e
BLAKE2b-256 checksum
How to use checksums
1dd0fe00b8f44e03c33aa6408c9defd902a47221fbd18045d155fbbac40b8736
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Release files / honker-0.5.0-cp311-abi3-manylinux_2_38_aarch64.whl

Download URL honker-0.5.0-cp311-abi3-manylinux_2_38_aarch64.whl
Size 1.9 MB
Tags CPython 3.11 Linux glibc 2.38+ ARM64 abi3
SHA-256 checksum
How to use checksums
ed99bd11a5dc47714b5484c8ba3dc12e10b6a871c610acff3488da822f3a34a4
BLAKE2b-256 checksum
How to use checksums
0534ba7836904f2c6d0e14d1257606f83d2ace01f0df63e5705c112da27a530e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Release files / honker-0.5.0-cp311-abi3-macosx_11_0_arm64.whl

Download URL honker-0.5.0-cp311-abi3-macosx_11_0_arm64.whl
Size 978.0 kB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
e7d7a1c566d6f9b43abe2f17115d7859b57e922dccd73f2edf16d07fd77d85bd
BLAKE2b-256 checksum
How to use checksums
695a6ac3666dbfaab0c14c3f70566eeb908872d348e2456616efe4eea9760596
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Release files / honker-0.5.0-cp311-abi3-macosx_10_12_x86_64.whl

Download URL honker-0.5.0-cp311-abi3-macosx_10_12_x86_64.whl
Size 995.7 kB
Tags CPython 3.11 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
190a827be3485af2aef66320adbbcba2a3595a03e6c4afe3bcd7f26e3961de82
BLAKE2b-256 checksum
How to use checksums
6b1977a30cfcafd6036cb409245dcccc2f354842cb12aa07ca044243aa55a4be
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Security for honker 0.5.0

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.

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