Skip to content

dashboard: 'Not sent (suppressed)' in send history for suppression-blocked sends - #58

Merged
Robertpaschal merged 1 commit into
mainfrom
fix/history-suppressed-label
Oct 24, 2026
Merged

Robertpaschal merged 1 commit into
mainfrom
fix/history-suppressed-label

Conversation

@Robertpaschal

Copy link
Copy Markdown
Owner

What

On a message page, the "More to " send-history panel printed each row's raw status. A re-send blocked before sending (status suppressed) sat in a list of real bounces and read as one more failed delivery. It now reads Not sent (suppressed).

Also on the blocked message's own record, the stop on the line was described as "provider feedback". A suppression block never reaches a provider, so it now says "blocked before sending". Real bounces, complaints and failures still say "provider feedback".

Root cause

Display only. The stored data already distinguishes the cases: the API and worker set messages.status = 'suppressed' and write a suppressed audit event (apps/api/src/routes/messages.ts, apps/worker/src/pipeline.ts ~L279). The panel rendered {m.status} with CSS capitalize, and eventsFrom() hard-coded "provider feedback" for any stop.

Change

  • New pure helper apps/dashboard/src/lib/send-history-label.ts (sendHistoryLabel, stopMethod).
  • message-card.tsx: the panel uses sendHistoryLabel(m.status).
  • live-status.tsx: the stopped station uses stopMethod(message.status).

Tests

send-history-label.test.ts: a regression test for suppressed, plus characterization tests showing every other status keeps its previous capitalised wording (Bounced, Complained, Delivered, Sent, Failed, Queued) and real stops still say "provider feedback".

Configs touched

None. No env, migrations, worker, API or infra changes.

Prod behaviour preserved

  • No data changes; the worker and API are untouched.
  • Every status other than suppressed renders exactly as before, so real bounces still show "Bounced".
  • Line stations, headline ("Not sent") and the activity trail are unchanged.

@Robertpaschal
Robertpaschal merged commit 328f5ad into main Oct 24, 2026
4 checks passed
@Robertpaschal
Robertpaschal deleted the fix/history-suppressed-label branch October 24, 2026 15:31
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