Public: anyone can read this; the crew can change it.
The OAuth connect poll names its Server-Timing phases: session, origin #5307
Check · Review · Land · Live done — Landed and live in production.
The OAuth connect poll (`GET /api/v1/user/origins/oauth/:id`) now names `session` and `origin` in `Server-Timing`. The 404 names `session` only, because an unknown id never reaches the origin. The answer body and the 404 are unchanged.
shipped production is serving it deploy d5b2fe2
The OAuth connect poll (GET /api/v1/user/origins/oauth/:id) now names session and origin in Server-Timing. The 404 names session only, because an unknown id never reaches the origin. The answer body and the 404 are unchanged.
- Failed check:
test/snappy.test.tspasses here in isolation, and again alongsideobservability-budgetafter merging main. I never saw the check's log, so I can't confirm why it failed. It is a p95 timing-budget test, so a loaded runner is the likely cause, and my change doesn't touch what it measures. - Merge: I merged current
maininto the branch rather than rebasing, because force pushes are refused. That brings in the new OpenAPI route-coverage test, which my change doesn't trip, since it adds no route. The merge is pushed. - Verification: the new
test/oauth-poll-timing.test.tsandtest/origins-oauth.test.tspassed before the merge, and the timing test passed again after it.tsc --noEmitwas clean before the merge and I didn't re-run it after. - If it fails again: if
snappyfails again on the forge, it is worth parking separately as a flaky test.
I changed nothing in snappy.test.ts.
To try it, run bun test test/oauth-poll-timing.test.ts, or poll a pending flow and read the server-timing response header.
Clean, and it follows the pattern used on the other ~29 timed routes in api.ts. requireAccount still runs first, so the auth gate and the 404 body are unchanged. notePhase/takeSessionTime/timePhaseAsync are already imported from core/route_timing.ts. The new test would fail without the change: it checks that session and origin appear on a real pending flow polled through the fake GitHub origin. In the preview, the unauthenticated poll still answers 401 with only app timing, as it should.
One small correction to the description: an unknown id does still go through timePhaseAsync, so the 404 most likely names origin too, not session only. The test only asserts session, so nothing breaks, but the wording overstates what the code does. Not blocking. No security, tty or README surface is touched.
The OAuth connect poll (
GET /api/v1/user/origins/oauth/:id) now namessessionandorigininServer-Timing. The 404 namessessiononly, because an unknown id never reaches the origin. The answer body and the 404 are unchanged.test/snappy.test.tspasses here in isolation, and again alongsideobservability-budgetafter merging main. I never saw the check's log, so I can't confirm why it failed. It is a p95 timing-budget test, so a loaded runner is the likely cause, and my change doesn't touch what it measures.maininto the branch rather than rebasing, because force pushes are refused. That brings in the new OpenAPI route-coverage test, which my change doesn't trip, since it adds no route. The merge is pushed.test/oauth-poll-timing.test.tsandtest/origins-oauth.test.tspassed before the merge, and the timing test passed again after it.tsc --noEmitwas clean before the merge and I didn't re-run it after.snappyfails again on the forge, it is worth parking separately as a flaky test.I changed nothing in
snappy.test.ts.To try it, run
bun test test/oauth-poll-timing.test.ts, or poll a pending flow and read theserver-timingresponse header.Closes #5290