Skip to content

feat(email): maximum delivery delay, Date-header latency and missed-probe detection - #938

Merged
fclairamb merged 22 commits into
mainfrom
feat/todos-2026-11-18
Nov 19, 2026
Merged

fclairamb merged 22 commits into
mainfrom
feat/todos-2026-11-18

Conversation

@fclairamb

@fclairamb fclairamb commented Nov 18, 2026 •

Copy link
Copy Markdown
Owner

What changed

Email check: maximum delivery delay (specs/done/2026/11/2026-11-18-03-email-max-delivery-delay.md)

  • New max_delivery_delay option on the email check, off by default. It must be lower than the check period, which is enforced on create (default period included), update, plan/dry-run and the validate endpoint.

  • Arrived late: a probe over the limit is recorded down, with its real latency (delivered after 13m29s, limit 10m). An explicit down comes first, then the sender-authentication failures, then the delay; messages are joined and auth is kept.

  • Never arrived: a new DeliveryWatch sweep (every 30 s, on the passive evaluator loop) writes one down row at send time + limit when a paired SMTP send has no matching email (sent at 09:52, not received after 10m). The periodic evaluation keeps that down until a newer real email arrives. A successful SMTP send now records sentAt in its output. An email check without a paired SMTP check keeps the period-based verdict.

  • Send time: X-SolidPing-Sent-At first, else the mail's Date header. The new sentAtSource output key (header/date) says which one was used. The sanity bound (negative or over 24 h means no latency) applies to both.

  • Duration: the delivery latency becomes the result duration. The response-time chart now works, and the existing slow rule (slow_threshold_ms) gives the Degraded tier.

  • Dashboard: a "Maximum delivery delay" field with its help line, and the delivery card shows a Date-header latency (and appears without an SMTP link for third-party mail). i18n in en, fr, de and es. Docs: features/check-types.md.

  • New db.Service.ListEnabledChecksByType (Postgres and SQLite).

  • Tests for the lines Codecov reported uncovered (DeliveryWatch failure paths and pairing, SMTP rejections, LastEvaluation, ListEnabledChecksByType in the shared db contract suite, delay validation). Two unreachable error branches were removed: the body-write check in doSendEmail (the writer's close reports it) and the uuid.NewV7 error in DeliveryWatch (uuid.Must).

Behaviour change

Every email check that receives third-party mail with a Date header now gets sentAt, sentAtSource, latencyMs and a non-zero duration, even without a limit. An unparsable X-SolidPing-Sent-At falls back to Date.

Decided by autopilot

  • Proposal step 5: the never-arrived detection uses a sweep on the passive loop rather than a shorter evaluation cadence, because the latter would write one row per tick.
  • Not in the spec: the timeout row is held against the next periodic evaluation so it isn't overwritten by up from an older signal, as the resolved question "nothing flips the check back up" requires.
  • No CHANGELOG.md entry, because release-please owns that file. The notes are in the commit bodies.

Batch gate: build, lint, make test, e2e typecheck and lint, and the full Playwright suite (1052 passed, 0 failed, 15 skipped by environment).


Specs filed with /todo, implemented on this branch by /implement-todos (or /autopilot). It gets the implemented label once every spec is done.

🤖 Generated with Claude Code

fclairamb and others added 4 commits November 18, 2026 20:23
…lts (fclairamb/solidping-business#93)

The "sender authentication incomplete" WARN only said "dmarc" when the
policy lookup failed (emailcheck/auth.go lookupDMARC): it now carries the
DNS cause ("dmarc: TXT record unavailable: ..."), the queried domain as a
dmarc_domain attribute, and tells a deadline already spent before the lookup
apart from a DNS failure. The abandoned-result reaper WARN now adds
reaped_by_region ("none" for rows without a region, such as the
"Check created" marker), so a burst can be traced to a checker.
Tests: auth_cover_test.go (temp failure entry, deadline case), the reaper
tests of both dialects and models.CountReaped; they fail before the fix.

Closes fclairamb/solidping-business#93

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…iramb/solidping-business#94)

With a search or a group filter active, the checks list force-expands every
group, but the header kept its button role, chevron and "Collapse group"
tooltip (checks.index.tsx GroupSection): clicks did nothing visible and each
one persisted "collapsed" to localStorage, so the group came back collapsed
once the filter was cleared. While forced, the header now has no toggle
(no chevron, role, aria-expanded or pointer) and a click writes nothing.
Test: e2e/check-group-collapse.spec.ts (search and group filter cases),
which fails before the fix.

Closes fclairamb/solidping-business#94

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@fclairamb fclairamb added frozen Batch PR under review: takes only its own fixes, new work goes to the next batch autopilot labels Nov 18, 2026
@fclairamb fclairamb changed the title feat: todos 2026-11-18 feat(checks): maximum delivery delay on email checks Nov 18, 2026
Frontend input, locales, docs and E2E for max_delivery_delay. CHANGELOG is
owned by release-please: feat(email) max_delivery_delay, delivery latency as
result duration, missed-probe delivery watch.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@codecov

codecov Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.87%. Comparing base (98297e8) to head (a1fe549).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #938      +/-   ##
==========================================
+ Coverage   90.84%   90.87%   +0.02%     
==========================================
  Files        1382     1384       +2     
  Lines      142877   143138     +261     
==========================================
+ Hits       129798   130075     +277     
+ Misses      13071    13055      -16     
  Partials        8        8              
Files with missing lines Coverage Δ
...rver/internal/checkers/checkemail/config/config.go 100.00% <100.00%> (ø)
...er/internal/checkers/checkemail/config/validate.go 97.72% <100.00%> (+1.06%) ⬆️
server/internal/checkers/checksmtp/checker.go 95.85% <100.00%> (+1.18%) ⬆️
server/internal/checkworker/backend/direct.go 87.01% <100.00%> (-0.99%) ⬇️
server/internal/checkworker/delivery_watch.go 100.00% <100.00%> (ø)
server/internal/checkworker/passive_evaluator.go 92.50% <100.00%> (+1.50%) ⬆️
server/internal/checkworker/worker.go 91.68% <100.00%> (-0.30%) ⬇️
server/internal/db/dbcontract/contract.go 100.00% <100.00%> (ø)
...r/internal/db/dbcontract/enabled_checks_by_type.go 100.00% <100.00%> (ø)
server/internal/db/postgres/degraded.go 95.91% <100.00%> (+1.04%) ⬆️
... and 6 more

... and 17 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

fclairamb and others added 12 commits November 19, 2026 00:16
Punch list: hold a watch timeout row against the regular passive
evaluation until a newer email arrives (deliveryTimeoutAt, passiveVerdict),
enforce max_delivery_delay < period on create/update/plan/validate with the
effective period, test the late mail after a timeout, record the mechanism
in the spec done notes.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
A mail without X-SolidPing-Sent-At now gets its send time from its Date
header (sentAtSource: date), so third-party mail has a latency and can be
judged late against max_delivery_delay. The latency no longer needs the
source-check header. An email check with no paired SMTP check gets no
timeout row.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The delivery card now renders for third-party mail too, and flags a latency
measured from the mail's Date header (sentAtSource: date). The maximum
delivery delay help line explains both send-time sources.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@fclairamb fclairamb changed the title feat(checks): maximum delivery delay on email checks feat(email): maximum delivery delay, Date-header latency and missed-probe detection Nov 19, 2026
@fclairamb fclairamb added the implemented Every spec of the PR is implemented and its batch gate was green label Nov 19, 2026
@fclairamb
fclairamb merged commit 8489326 into main Nov 19, 2026
38 checks passed
@fclairamb
fclairamb deleted the feat/todos-2026-11-18 branch November 19, 2026 06:37
fclairamb added a commit that referenced this pull request Nov 19, 2026
…d, Postgres Unix socket (#939)

Stacked on #938: merge it first.

## What changed

- **Status updates in several languages**
(`specs/done/2026/11/2026-11-18-04-status-update-translations.md`). A
nullable `translations` column on `status_updates` and
`incident_publications`, keyed by language (`{"fr": {"title": "...",
"body": "..."}}`). The API accepts and returns it (PATCH: absent keeps
it, `{}`/`null` clears it, a map replaces it), the public status page
returns it, and invalid entries answer 422 `VALIDATION_ERROR`. The dash0
editors (status updates, publications) get an "Other languages" block,
also shown on the design reference page. The status page and the TV
board show, for a visitor in language L: the translation in L, else the
generated text in L, else the page-language text. Mails, webhooks and
feeds keep the page language. Migration 038 is extended, not a new one:
a dev database that already ran 038 needs a reset.
- **First admin gets a random password**
(`specs/done/2026/11/2026-11-19-01-first-boot-random-admin-password.md`,
#943). Outside the `test` and `demo` run modes, a fresh install seeds
`[email protected]` with a 20-character random password, printed once
in a `First login` WARN line, still forced to change at first login.
`SP_ADMIN_PASSWORD` sets it instead. If the line is lost, a boot with
`SP_ADMIN_PASSWORD` resets the seeded admin's password, only while it
has never been rotated. Docs: a "Password of the first admin" section in
`configuration/authentication.md`, and every install page, the Helm
NOTES and the READMEs updated. `make dev` keeps `solidpass` via
`SP_ADMIN_PASSWORD`.
- **Postgres over a Unix socket** (#944). `host=/var/run/postgresql`
names the socket directory, as with libpq: the DSN is rewritten for
bun's pgdriver and for the LISTEN notifier. There's a test against a
real socket-only Postgres, and a "Unix-domain socket" section in
`configuration/database.md`.

## Behaviour change

New installs in the default run mode no longer accept
`[email protected]` / `solidpass`: the password is in the startup logs,
or set by `SP_ADMIN_PASSWORD`. Existing databases are not affected. This
belongs in the release notes. It isn't marked `!`: the release-please
config has no `bump-minor-pre-major`, so a `!` would cut 1.0.0.

## Decided by autopilot

- First-boot password, run modes: `test` and `demo` keep `solidpass`,
the default mode gets a random one (spec's recommended answer).
- First-boot password, reprint: no, it is printed once. Recovery goes
through `SP_ADMIN_PASSWORD` while the seeded admin hasn't rotated
(spec's recommended answer).
- Translations: invalid input answers 422 `VALIDATION_ERROR` (the repo's
`WriteValidationError`), not the 400 the spec said. The spec was
updated.
- Issue #943 was turned into a spec rather than fixed directly: it
touches the superadmin login and spans many files.

## Batch gate

Build, `lint-back`, `make test` (287 packages), and dash0/status0
typecheck and e2e lint are green. The full dash0 Playwright run had 1045
passed, 4 failed, 3 flaky and 15 skipped, at load average ~27 from other
sessions. On reruns, `badges.spec.ts:557`,
`check-scheduling.spec.ts:248` and
`check-multi-picker-uuid-chips.spec.ts` still time out on serial API
calls. A side-by-side run of `origin/main` under the same load fails the
same tests, and one more. `POST`/`PATCH /checks` latencies are identical
on both builds (p50 ~200/120 ms, p90 ~4.8/4.2 s). So it's load, not this
batch. CI has the last word.

Closes #943
Closes #944

---

Specs filed with `/todo`, implemented on this branch by
`/implement-todos` (or `/autopilot`). It gets the `implemented` label
once every spec is done.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
fclairamb added a commit that referenced this pull request Nov 19, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.52.0](v0.51.0...v0.52.0)
(2026-11-19)


### Features

* **checks:** Pingdom TMS and Chrome Recorder import, named steps and
test runs, richer selectors and basic auth for JS browser checks
([#909](#909))
([1240c57](1240c57))
* **dash0:** switch the dashboard language with ?lang= on any URL
([#926](#926))
([c2640ae](c2640ae))
* **email:** maximum delivery delay, Date-header latency and
missed-probe detection
([#938](#938))
([8489326](8489326))
* **showcase:** cut the published video in any dashboard language
([#932](#932))
([d940da5](d940da5))
* **showcase:** take the dashboard stills in any dashboard language
([#925](#925))
([5104606](5104606))
* status updates in several languages, random first admin password,
Postgres Unix socket
([#939](#939))
([a69424f](a69424f))


### Bug Fixes

* **dash0:** chart dates follow the dashboard language
([#928](#928))
([eae2951](eae2951))
* **deps:** update github.com/dop251/goja digest to 0802ca1
([#920](#920))
([3524928](3524928))
* **deps:** update github.com/dop251/goja digest to 2eded47
([#911](#911))
([a8496d4](a8496d4))
* **deps:** update github.com/dop251/goja digest to 8dfece3
([#935](#935))
([98297e8](98297e8))
* **deps:** update go dependencies (non-major)
([#907](#907))
([41187dc](41187dc))
* **deps:** update go dependencies (non-major)
([#927](#927))
([fcef3fc](fcef3fc))
* **deps:** update go dependencies (non-major)
([#940](#940))
([0fd9228](0fd9228))
* **deps:** update module github.com/a2aproject/a2a-go/v2 to v2.9.0
([#922](#922))
([fe48c84](fe48c84))
* **deps:** update module github.com/posthog/posthog-go to v2
([#924](#924))
([eab03f2](eab03f2))
* **deps:** update module github.com/posthog/posthog-go to v2
([#929](#929))
([545e621](545e621))
* **deps:** update module github.com/posthog/posthog-go to v2
([#930](#930))
([82b03cc](82b03cc))
* **deps:** update module github.com/rabbitmq/amqp091-go to v1.17.0
([#916](#916))
([6974177](6974177))
* **deps:** update module
github.com/standard-webhooks/standard-webhooks/libraries to v1
([#931](#931))
([7b9d073](7b9d073))
* **deps:** update module golang.org/x/net to v0.63.0
([#923](#923))
([7d0fac9](7d0fac9))
* DMARC temperror cause, reaper regions, force-expanded group headers
([#934](#934))
([99f955d](99f955d))
* **i18n:** say "Check" instead of "Prüfung" in German
([#910](#910))
([696dcf8](696dcf8))
* **i18n:** translate generated incident, status-page and validation
text ([#913](#913))
([92bb05a](92bb05a))
* **security:** no paging contacts via impersonation/PAT, shared MCP
probe caps, browser WebSocket egress, analytics key replay
([#946](#946))
([8d51875](8d51875))
* **security:** per-org test-run slots, typed credentials of imported
transaction checks go to secrets
([#933](#933))
([51914b3](51914b3))
* **security:** Telegram bot membership and role checks, admin-only
email suppressions, mask import payload in replay
([#914](#914))
([55ffc4b](55ffc4b))
* Slack events after ack, region badge clicks, WHOIS deadline, legacy
agent warning, empty check groups
([#917](#917))
([65b00e2](65b00e2))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automerge autopilot frozen Batch PR under review: takes only its own fixes, new work goes to the next batch implemented Every spec of the PR is implemented and its batch gate was green

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant