Skip to content

test(server): don't report cancelled calls as unmocked network - #53

Merged
Tarquinen merged 1 commit into
devfrom
fix-family-test-flake
Nov 12, 2026
Merged

Tarquinen merged 1 commit into
devfrom
fix-family-test-flake

Conversation

@Tarquinen

Copy link
Copy Markdown
Member

`propagatesHTTPFailuresFromEveryRequiredEndpoint` failed now and then in CI with an isolation error. When one family request fails, the others are cancelled, but OkHttp still runs the test network block for a call cancelled before it started, often after the test had closed its fixture, so it was reported as an unmocked network request.

Now the test network block fails a cancelled call without reporting it, since a cancelled call never reaches the network. App code is unchanged.

  • Repeated the test in-process on the VM: 6/1000 and 267/5000 failures before, 0/5000 and 0/20000 after.
  • `scripts/check.sh :server` passes.

OkHttp still runs application interceptors for a call cancelled before its
dispatcher thread picked it up. When a family load failed, the cancelled
sibling request could reach TestNetworkBlock after the test closed its
fixture, so it was reported as an unmocked request and
propagatesHTTPFailuresFromEveryRequiredEndpoint failed now and then. A
cancelled call never reaches the network, so the block now just fails it.

Verified on the VM: the test repeated in-process failed 6/1000 and 267/5000
times before, 0/5000 and 0/20000 after; scripts/check.sh :server passes.
@Tarquinen
Tarquinen merged commit cce9964 into dev Nov 12, 2026
3 checks passed
Tarquinen added a commit that referenced this pull request Nov 12, 2026
…nto feat/assistant

Conflicts kept both sides: the root page keeps the Assistant row next to #49's badge rows,
the Experimental count still includes the assistant, and the sessions parity row keeps the
archived-session routes and the assistant's session note. The Assistant experiment loses its
caption, as #49 removed row captions; its footer now says what it does.
@Tarquinen Tarquinen mentioned this pull request Nov 12, 2026

This branch was previously deployed

1 inactive deployment
release — eed892a9 Deployed Nov 12, 2026 by Tarquinen via check #159
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