Skip to content

fix(chell): quiet query polling, fast zero-match completion, spinner ghosting#38

Merged
rudolphpienaar merged 1 commit into
mainfrom
fix/query-poll-noise
Jul 5, 2026
Merged

fix(chell): quiet query polling, fast zero-match completion, spinner ghosting#38
rudolphpienaar merged 1 commit into
mainfrom
fix/query-poll-noise

Conversation

@rudolphpienaar

Copy link
Copy Markdown
Member

Two field reports from interactive use, both reproduced and fixed:

1. Zero-match query = 26 error lines + 60s timeout. pacsQuery_createAndWait probes pacsQuery_resultDecode every 2s; each probe pushes PACS query N has no result payload onto the error stack, and a query matching nothing rode the full 60s timeout. Now: each failed probe pops the transient error it just pushed, and once the PACS reports succeeded with no stored payload (two grace polls cover result-write lag) the wait completes immediately through the existing "no studies found" path.

Before / after, live against the instance with a no-match accession:

[pacsQuery_resultDecode] | PACS query 2771 has no result payload.   ← ×26
[pacsQuery_createAndWait] | query: Timed out waiting for query 2771 result.   (60s)
⚠ Query 2773 complete — no studies found.    (7.6s, exit 0)

2. Spinner ghosting (⣯ Query 2772 — succeeded (12.7s)ber:2324123... (0.7s)): the frame renderer wrote over the previous line with \r but no erase, so shorter messages left the tail of longer ones. The frame now clears to end-of-line first.

Tests: two new fake-timer cases (transient error popped per probe; succeeded-without-payload completes early, no timeout). chell suite 610 green; test query cleaned from the instance.

…ghosting

The query poll probed the result decode every two seconds and each probe
pushed 'has no result payload' onto the error stack — a zero-match query
printed ~26 identical error lines and then timed out after 60s. The poll
now pops the transient error it just caused, and once the PACS reports
the query succeeded with no stored payload (plus two grace polls for
result-write lag) it completes immediately through the existing
'no studies found' path: one line, ~7s, exit 0.

The spinner frame now erases to end-of-line before writing, so a shorter
status no longer shows the tail of a longer previous message.
@rudolphpienaar rudolphpienaar merged commit 999a28b into main Jul 5, 2026
3 checks passed
@rudolphpienaar rudolphpienaar deleted the fix/query-poll-noise branch July 5, 2026 16:43
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