Skip to main content

fanferro

Fast, robust SNS + SQS messaging for Python, powered by a Rust core.

fan-out (SNS → SQS) · fanfare (announcing to a topic) · ferro (iron: the Rust core)

import fanferro
from pydantic import BaseModel                  # or dataclasses, msgspec, protobuf, ...


@fanferro.message_type("checkout.order_placed.v1")
class OrderPlaced(BaseModel):
    order_id: str
    amount_cents: int


client = fanferro.Client(
    source="urn:service:checkout",
    provisioning=fanferro.Provisioning.ensure(),  # create missing resources (default: must exist)
)
orders = client.topic("orders")
billing = client.queue("billing", dead_letter=fanferro.DeadLetterQueue("billing-dlq"))
client.subscription(orders, billing)
consumer = client.consumer(billing, concurrency=20)


@consumer.route(OrderPlaced)
async def charge(order: OrderPlaced) -> None:
    ...                                    # return → ack · raise → retry with backoff → DLQ


async def main() -> None:
    async with client:                     # connect + provision declared resources
        await orders.publish(OrderPlaced(order_id="o-1", amount_cents=1299))
        await consumer.run()               # SIGTERM → graceful drain

Status: 0.x - the API may still change between minor versions.

Install

uv add fanferro                   # pip install fanferro
uv add "fanferro[all]"            # + pydantic, protobuf, msgspec, opentelemetry-api

Highlights

  • Handlers are plain typed functions. Return to ack, raise to retry. No receipt handles.
  • Your own types. Pydantic, dataclasses, msgspec, protobuf, JSON or raw bytes.
  • Routing on anything. Message type, attribute, body field or topic.
  • Safe by default. Heartbeats, retries with backoff, dead-letter queues, graceful shutdown.
  • Infrastructure in code. Declared queues, topics and subscriptions are checked or created.
  • Tests without AWS or Docker. An in-memory broker runs the same engine you deploy.
  • Mistakes caught early. Bad names, sizes and signatures fail before any network call.
  • Observable. Typed events, structured logs, hooks and OpenTelemetry.
  • The hard parts included. Large payloads via S3, outbox, idempotency, FIFO ordering.
  • Fast. A Rust core, full batches and little Python work per message.
  • No required dependencies. Fully typed, Python 3.12-3.15, wheels for Linux, macOS, Windows.

Performance

  • Rust does the heavy lifting. Signing, HTTP, the SQS and SNS protocols and batching.
  • Full batches, overlapping. Messages are received ten at a time, the next batch prefetched.
  • Acks don't block handlers. Deletes are batched in the background while the next message runs.
  • Little Python per message. Only your codecs, routing and handlers run on the event loop.
  • Lean defaults. Small messages, no redundant checksums, no tracing work unless enabled.

Benchmarks and how to run them: Performance.

Learn more

Getting started First publisher and consumer, local development
Publishing · Consuming Options, batches, FIFO, routing, concurrency, shutdown
Failure handling Retries, dead-letter queues, poison messages
Provisioning Declaring resources, failure modes, IAM permissions
Message formats · Large payloads Codecs, envelopes, claim checks
Observability Events, logging, hooks, OpenTelemetry, metrics
Patterns Transactional outbox, inbox, fan-out, versioning, ordering
Testing · Deployment In-memory broker, MiniStack, production setup
Examples Runnable examples for every feature
Reference Configuration, events, attributes, errors
Architecture How it is built and why, with decision records

Using an AI coding agent? Point it at fanferro guide (the usage guide shipped with the package) or copy skills/fanferro into your project's skills.

Contributing

See AGENTS.md (for humans and AI agents): uv sync, make check, conventional commits.

License

MIT

Metadata

Release files for fanferro 0.6.0

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

Source distribution (sdist)

Source distribution for fanferro 0.6.0
File Size Uploaded Provenance Actions
fanferro-0.6.0.tar.gz 314.0 kB With provenance Details for fanferro-0.6.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for fanferro 0.6.0
File Actions
fanferro-0.6.0-cp312-abi3-win_arm64.whl CPython 3.12 abi3 Windows ARM64 Details for fanferro-0.6.0-cp312-abi3-win_arm64.whl
fanferro-0.6.0-cp312-abi3-win_amd64.whl CPython 3.12 abi3 Windows x86-64 Details for fanferro-0.6.0-cp312-abi3-win_amd64.whl
fanferro-0.6.0-cp312-abi3-musllinux_1_2_x86_64.whl CPython 3.12 abi3 Linux musl 1.2+ x86-64 Details for fanferro-0.6.0-cp312-abi3-musllinux_1_2_x86_64.whl
fanferro-0.6.0-cp312-abi3-musllinux_1_2_aarch64.whl CPython 3.12 abi3 Linux musl 1.2+ ARM64 Details for fanferro-0.6.0-cp312-abi3-musllinux_1_2_aarch64.whl
fanferro-0.6.0-cp312-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.12 abi3 Linux glibc 2.17+ x86-64 Details for fanferro-0.6.0-cp312-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
fanferro-0.6.0-cp312-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.12 abi3 Linux glibc 2.17+ ARM64 Details for fanferro-0.6.0-cp312-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
fanferro-0.6.0-cp312-abi3-macosx_11_0_x86_64.whl CPython 3.12 abi3 macOS 11.0+ x86-64 Details for fanferro-0.6.0-cp312-abi3-macosx_11_0_x86_64.whl
fanferro-0.6.0-cp312-abi3-macosx_11_0_arm64.whl CPython 3.12 abi3 macOS 11.0+ ARM64 Details for fanferro-0.6.0-cp312-abi3-macosx_11_0_arm64.whl

Total release size: 54.6 MB

Release files / fanferro-0.6.0.tar.gz

Download URL fanferro-0.6.0.tar.gz
Size 314.0 kB
Tags Source
SHA-256 checksum
How to use checksums
2e3272835b8b5f1daf145a4ab1679ccd1fa4bf9f3037fc662fabd9e144f433a9
BLAKE2b-256 checksum
How to use checksums
df3f887f163fe6bef8d154e704ce6fcdcc0df33b325a2edf3d45c9a056889f4e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / fanferro-0.6.0-cp312-abi3-win_arm64.whl

Download URL fanferro-0.6.0-cp312-abi3-win_arm64.whl
Size 6.8 MB
Tags CPython 3.12 Windows ARM64 abi3
SHA-256 checksum
How to use checksums
74da16f355ebfd085f5cb496ba50a6831ff47284e77d8b9af81ea289bdf17e4b
BLAKE2b-256 checksum
How to use checksums
a1530e1533bfe69967de1cccb3c3ae5ebbb58c8f85f2de9b043691c5ad209c50
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / fanferro-0.6.0-cp312-abi3-win_amd64.whl

Download URL fanferro-0.6.0-cp312-abi3-win_amd64.whl
Size 7.1 MB
Tags CPython 3.12 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
60b6f3b031cf16d72cfda186a27bafc45a64dcb4d3eab985b4b719631b89e8eb
BLAKE2b-256 checksum
How to use checksums
f8e011c6c03c688e3b929bb6449aa35b821508ebcc504e51e19e5200363c0af8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / fanferro-0.6.0-cp312-abi3-musllinux_1_2_x86_64.whl

Download URL fanferro-0.6.0-cp312-abi3-musllinux_1_2_x86_64.whl
Size 7.1 MB
Tags CPython 3.12 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
10bc456f77b937e84f193fc6cfc75b0d88b505baaee4c71d1d0cc632dfd3a21a
BLAKE2b-256 checksum
How to use checksums
daf20f53ce1c48e0a55e02f3f78414264bb786eb00ee482f7913065f78a479f4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / fanferro-0.6.0-cp312-abi3-musllinux_1_2_aarch64.whl

Download URL fanferro-0.6.0-cp312-abi3-musllinux_1_2_aarch64.whl
Size 6.7 MB
Tags CPython 3.12 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
997e5245e67a825e24959ef35218987e854740960486b662b9ba967e73313ce1
BLAKE2b-256 checksum
How to use checksums
ae0f41148733668538b7ce3a9d1352e15fce8f10b6007ec3d2ab1b551c817838
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / fanferro-0.6.0-cp312-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL fanferro-0.6.0-cp312-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 7.1 MB
Tags CPython 3.12 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
35a62cdde34d59a5ea450d4e74321286f04d08f0086a5dbb639e5cf24491a169
BLAKE2b-256 checksum
How to use checksums
066bfa1a9936a7b0bbd38f7d4cb4cadc1dde704c9448b059a334e9246ef9fa18
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / fanferro-0.6.0-cp312-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL fanferro-0.6.0-cp312-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 6.7 MB
Tags CPython 3.12 Linux glibc 2.17+ ARM64 abi3
SHA-256 checksum
How to use checksums
52fdd0ff857fb7a4217d4408511348a1d18d3094c9e7973c25e31166aa008c37
BLAKE2b-256 checksum
How to use checksums
4ce99ab1386f59ae8167317bffc99260308043d7580f2666aa57bcd8e65f220e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / fanferro-0.6.0-cp312-abi3-macosx_11_0_x86_64.whl

Download URL fanferro-0.6.0-cp312-abi3-macosx_11_0_x86_64.whl
Size 6.9 MB
Tags CPython 3.12 abi3 macOS 11.0+ x86-64
SHA-256 checksum
How to use checksums
2a2e0d630379957d09511f5a5d1f8cf1370f060f8bf0cc1ace165d91923f145d
BLAKE2b-256 checksum
How to use checksums
692e9cf8a16b2d155517e1a4ed626a61f5ca577cf01396df64882f5e36ccf9f8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / fanferro-0.6.0-cp312-abi3-macosx_11_0_arm64.whl

Download URL fanferro-0.6.0-cp312-abi3-macosx_11_0_arm64.whl
Size 5.9 MB
Tags CPython 3.12 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
30f3b0344a8116cc26507083acc1d1021bcc15e0891df719347705fa09ea8aae
BLAKE2b-256 checksum
How to use checksums
e21529946706cecf26424428e60f5f8ed3e37297ebe5f7dbe5524992aafcbf75
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Security for fanferro 0.6.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.

Full provenance

All 9 files in this release have been uploaded with provenance metadata.

Select from 9 files

Attestation for fanferro-0.6.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

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