fix: unbreak the image build, and stop filing expected 4xx as runtime exceptions

The service-worker deletion in 15e0e0872 missed the Dockerfile, which still ran
`workbox generateSW config/workbox-config.js`. Build and Test passed; the image
build failed on the deleted config and the deploy was skipped.

While in there: runTracing marked a span Error for *any* exception propagating
through it, including Servant 4xx thrown via the Error effect — which
`effToHandler` catches correctly one layer up, but only after the span has
already been marked. Deliberate refusals therefore became runtime-exception
issues: "This live tail has expired", "This project already has 2 live tails
open", "The complete record is not available yet" accounted for ~870 open
issues on their own.

OTel's convention for a SERVER span is that 4xx leaves the status unset — the
caller erred, the server answered correctly. 5xx still marks the span.

Matched on the rendered exception rather than fromException: the value in
flight is effectful's ErrorWrapper, which hides its payload behind an unsafely
coerced Any, so there is no ServerError to downcast to at that point.

workbox-cli is still installed in Dockerfile.deps; left alone rather than force
a base-image rebuild tonight.
This commit is contained in:
Anthony Alaribe 2026-08-31 23:39:30 +02:00
commit 8a61f2e606
2 changed files with 33 additions and 2 deletions