Skip to content

fix(archivist): stop losing long document filings to a timeout - #68

Merged
arthware-dev merged 1 commit into
mainfrom
fix/archivist-timeout-retry
Aug 4, 2026
Merged

fix(archivist): stop losing long document filings to a timeout#68
arthware-dev merged 1 commit into
mainfrom
fix/archivist-timeout-retry

Conversation

@arthware-dev

Copy link
Copy Markdown
Contributor

Archiving a long email or scan ran past two budgets that were set for a
chat bot, not a document pipeline: the 180s handler timeout and the 120s
per-call LLM timeout. A 30K-token prefill on a local model gets cancelled
mid-flight by the latter, so the work was thrown away while it was still
making progress. Now 8 minutes and 5 minutes.

The failure was also invisible. _send_error replied to event.event_id,
which for a reaction-triggered archive is the reaction event, so the notice
landed loose in the room timeline instead of the thread and nothing marked
the card. It now anchors on the message the user acted on: a cross next to
the eyes the handler already left, and the reason as a threaded reply.

Reacting with the retry emoji on that message runs the work again, covering
uploads as well as source cards. Re-adding the paperclip already worked for
cards; uploads had no retry at all.

Archiving a long email or scan ran past the 180s handler budget and
the 120s per-call LLM budget, killing work that was still making
progress. Now 8 minutes and 5 minutes.

Failures are also visible where they happened: a cross on the message
and the reason in its thread, instead of a loose reply in the room
timeline. Reacting with the retry emoji on that message runs it again.
@arthware-dev
arthware-dev merged commit 9d961b8 into main Aug 4, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant