From c256b2b5e658ba7a803fdf3700f2aad48afb0afe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20Contreras=20Guill=C3=A9n?= Date: Fri, 12 Jun 2026 19:27:48 +0200 Subject: [PATCH] =?UTF-8?q?fix(eda):=20worker=20subscribed=20to=20a=20dead?= =?UTF-8?q?=20topic=20=E2=80=94=20async=20extractions=20never=20processed?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The async worker's PostgresEventBus subscribed to `flydocs.jobs` (the `pyfly.eda.destinations` default), but the submit handler publishes `extraction.submitted` to `jobs_topic` = `flydocs.extractions`. The `worker` container therefore consumed from a topic nothing publishes to, so every queued async extraction sat unprocessed until the reaper revived it (~10 min later). In practice queue-backed submissions never completed. Align the `destinations` default to `flydocs.extractions` (matching `IDPSettings.jobs_topic`). Still env-overridable via `FLYDOCS_EDA_DESTINATIONS`; `bbox-worker` keeps its own `flydocs.extractions.post_processing` override. Also bump the locked pyfly dependency to 26.6.99 and release 26.6.4. --- CHANGELOG.md | 17 +++++++++++++++++ pyfly.yaml | 8 +++++--- pyproject.toml | 2 +- uv.lock | 2 +- 4 files changed, 24 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 32babf2..7da673e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,23 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project uses **CalVer `YY.M.PP`** (PEP 440 may normalise patch numbers for the Python wheel — e.g. `26.06.00` → `26.6.0`). +## [26.6.4] - 2026-06-12 + +### Fixed + +- **Async worker consumed no jobs (wrong EDA topic).** `pyfly.eda.destinations` + defaulted to `flydocs.jobs`, but the submit handler publishes + `extraction.submitted` to `jobs_topic` = `flydocs.extractions`. The `worker` + container therefore subscribed to a topic nothing publishes to, so every + queued async extraction sat unprocessed (only the reaper eventually revived + it). Aligned the `destinations` default to `flydocs.extractions` — still + env-overridable via `FLYDOCS_EDA_DESTINATIONS`, and `bbox-worker` keeps its + own `flydocs.extractions.post_processing` override. + +### Changed + +- Bumped the locked `pyfly` framework dependency to `26.6.99`. + ## [26.6.3] - 2026-06-12 ### Added diff --git a/pyfly.yaml b/pyfly.yaml index 3d5ca3c..e44e6d1 100644 --- a/pyfly.yaml +++ b/pyfly.yaml @@ -68,9 +68,11 @@ pyfly: enabled: true provider: ${FLYDOCS_EDA_ADAPTER:postgres} # Both knobs are env-overridable so the ``bbox-worker`` container can - # subscribe to ``flydocs.bbox.refine`` under its own consumer - # group while the main ``worker`` keeps consuming ``flydocs.jobs``. - destinations: ${FLYDOCS_EDA_DESTINATIONS:flydocs.jobs} + # subscribe to ``flydocs.extractions.post_processing`` under its own + # consumer group while the main ``worker`` consumes ``flydocs.extractions`` + # (matching ``IDPSettings.jobs_topic`` -- the topic the submit handler + # publishes ``extraction.submitted`` to). + destinations: ${FLYDOCS_EDA_DESTINATIONS:flydocs.extractions} group: ${FLYDOCS_EDA_GROUP:flydocs-workers} postgres: dsn: ${FLYDOCS_DATABASE_URL:postgresql+asyncpg://idp:idp@localhost:5432/flydocs} diff --git a/pyproject.toml b/pyproject.toml index bead04d..684499b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -2,7 +2,7 @@ name = "flydocs" # CalVer YY.MM.PP -- bumped per release. Note that PEP 440 normalises # ``26.05.01`` -> ``26.5.1`` in the built wheel filename. -version = "26.6.3" +version = "26.6.4" description = "Pure-multimodal Intelligent Document Processing service: structured fields + bounding boxes, validation, authenticity checks, LLM judge, and a business-rule engine. Sync + queue-backed async APIs over fireflyframework-pyfly and -agentic. Part of Firefly OperationOS, platform-agnostic by design." readme = "README.md" requires-python = ">=3.13" diff --git a/uv.lock b/uv.lock index 778a34e..f03d387 100644 --- a/uv.lock +++ b/uv.lock @@ -3942,7 +3942,7 @@ wheels = [ [[package]] name = "pyfly" -version = "26.6.98" +version = "26.6.99" source = { editable = "../../fireflyframework/fireflyframework-pyfly" } dependencies = [ { name = "pydantic" },