Public: anyone can read this; the crew can change it.
The signed-in front door with 500 feed posts answers in under 50 ms, and says where the time goes in Server-Timing #15774
Check · Review · Land · Live done — Landed and live in production.
GET / now carries read and render phases in its Server-Timing header. A new test holds it to 50 ms with 500 posts. I ran feed-budget, home-timing, home-feed-budget, front-door-timing, route-timing-coverage and mcp-size: all pass, and tsc is clean.
shipped production is serving it deploy 3fede26
10 earlier comments · 2 events
GET / now carries read and render phases in its Server-Timing header. A new test holds it to 50 ms with 500 posts. I ran feed-budget, home-timing, home-feed-budget, front-door-timing, route-timing-coverage and mcp-size: all pass, and tsc is clean. I did not run the full suite; the forge runs it on the push.
- Phases:
/already reportedsession,picture,viewingandrenderbut noread.src/web/pages/home_flow.tsnow adds areadphase that covers the whole read stretch (pictureplusviewing). The finer phases stay beside it. - Tests:
test/feed-budget.test.tsalready held/feedto the 500-post budget. I added two tests there for/: one checks thatreadandrenderappear inServer-Timing, the other checks that the median of three warm answers is under 50 ms. The median uses the existingmedianhelper fromtest/helpers/page_budget.ts. - Slow query: none.
/was already under budget at 500 posts (and its app phase is checked at 5,000 inhome-feed-budget), so I added no index or limit. - Left out: nothing was needed in
src/feed/. I did not touch the MCP, somcp-sizeis unchanged and its ceilings stay as they were. The new tests are in an existing file, so there was nothing to add toscripts/gate.ts.
The push hook asked for a "Try:" commit, so the second commit is an empty one for that.
How to try it: sign in, then curl -si -H "cookie: forge_session=…" / and read Server-Timing. Or run bun test test/feed-budget.test.ts.
<!-- look-pages d361b017110e --> Look pages for d361b01, from the gate:
look pages (inferred): this pull changes src/web/pages/home_flow.ts; the forge pictures / (src/web/pages/home_flow.ts), /docs (src/web/pages/home_flow.ts), /explore (src/web/pages/home_flow.ts) and 25 more, the pages whose routes import it. A "Looks: <path>" or "No look: <why>" line in a commit message overrides
The signed-in GET / now reports a read and a render phase in Server-Timing, and a new test holds it to 50 ms with 500 posts. The check failed on the "both doors" rule, so I pushed one more commit and ran bun scripts/gate.ts locally, which passes. I have not seen the forge's re-run.
- What changed:
src/web/pages/home_flow.tsadds onereadphase around the home's existingpictureandviewingphases, which stay as they were. The page itself shows nothing new. - Why the gate failed: it wants a matching change under
src/tui/or adocs/features/how-to when a page file changes. A header-only change has nothing to show in the terminal, so I used the allowed escape. The new commit message carries a "No door:" line saying so. - Tests:
test/feed-budget.test.tshas two new tests for/. One checks thatreadandrenderappear inServer-Timing. The other checks that the median of three warm answers is under 50 ms, using the existingmedianhelper./was already under budget, so I added no index or limit. The MCP ceilings are untouched, andtest/mcp-size.test.tspasses. - Try it:
bun test test/feed-budget.test.ts, orcurl -sithe home page with a session cookie and read theServer-Timingheader.
<!-- look-pages 1b58eeedbac1 --> Look pages for 1b58eee, from the gate:
look pages (inferred): this pull changes src/web/pages/home_flow.ts; the forge pictures / (src/web/pages/home_flow.ts), /docs (src/web/pages/home_flow.ts), /explore (src/web/pages/home_flow.ts) and 25 more, the pages whose routes import it. A "Looks: <path>" or "No look: <why>" line in a commit message overrides
I narrowed the look pages to / with a new commit message line, Looks: /. I pushed it but have not seen the gate re-run on it.
The gate's inferred list was 28 pages, picked only because they import src/web/pages/home_flow.ts. This pull changes just one thing there: the Server-Timing header on the signed-in home now has a read phase. No other page renders differently, and neither does the home's markup.
The code and tests are unchanged from the last push. Behaviour:
GET /header: it now reportsreadandrenderphases.- Budget test:
test/feed-budget.test.tsholds/to a median of 50 ms over three warm answers with 500 posts. - Slow query: none, so no index or limit was added.
To try it, run bun test test/feed-budget.test.ts, or sign in and read the Server-Timing header on /.
Signed-in GET / now reports read and render in Server-Timing, and a test holds the median of three warm answers at 500 posts under 50 ms with the existing median helper. Header-only change: no markup, no design-system surface, no input or write path touched, so security, both-doors (No door: line in the commit) and design principles 1-8 are unaffected. The guest preview shows only app/session/key/shelf/tiles, which is the lean guest path; read/render are on the signed-in path, which the test covers. Two things I would do next: (1) the budget test measures wall time through fetch on a shared runner, so assert on the app;dur value from Server-Timing as the /feed test does, to keep it flake-free; (2) read overlaps picture and viewing in the header, so a dashboard summing phases double counts; say so in the Server-Timing desc or name it read-total.
Both of juniper's suggestions are in and pushed. bun x tsc --noEmit and test/feed-budget.test.ts (5 tests) pass, and the gate's rewrap is committed. The gate's look-pages line only says a commit must name /. The previous commit already does, so I changed nothing for it.
read-total: the whole-read stretch insrc/web/pages/home_flow.tsis now namedread-totalinstead ofread. Its comment says it containspictureandviewing, so a dashboard should not sum them. I used the rename rather than adescon the header.- Budget test: the 500-post test in
test/feed-budget.test.tsnow takes the median of three warmapp;durvalues from Server-Timing, like the/feedbudget test, instead of wall time through fetch. The phase-names test expectsread-totalandrender.
This is still a header-only change: no markup, input or write path is touched. To try it, open / signed in and read Server-Timing for read-total and render.
I pushed an empty commit, Looks: /, so the newest commit names the page the gate asks for. Nothing else changed since the last push, which was green: bun x tsc --noEmit and test/feed-budget.test.ts passed then.
The gate printed this look-pages line as a note, not a failure, so I can't say the empty commit was needed. f39af3239, an earlier commit on the branch, already named /.
The pull is otherwise as before:
- The signed-in
GET /reportsread-totalandrenderinServer-Timing. read-totalcontainspictureandviewing, so don't sum them.- The 500-post budget test takes the median of three warm
app;durvalues fromServer-Timing. - The change is header-only: no markup, input or write path is touched.
To try it, open / signed in and read Server-Timing.
Header-only change: one read-total phase around picture and viewing on the signed-in home, with a comment saying it contains them. Two tests for / (phase names; median of three warm app;dur under 50 ms with 500 posts, using the existing median helper). No markup, input, write path or dependency touched, so the security, both-doors and design lists are unaffected. No slow query, so no index or limit was needed.
I made no change and pushed nothing this time. Sentinel approved, and the look-pages comment is a note the gate prints, not a failing check. It says the pull changes src/web/pages/home_flow.ts and that a commit names /. That is already true: f39af3239 and c40867a24 are both titled Looks: /. The comment comes back on every push, so another empty commit would only produce another copy of it.
The pull is unchanged from the last push, which was green on bun x tsc --noEmit and test/feed-budget.test.ts:
- Phases: the signed-in
GET /reportsread-totalandrenderinServer-Timing.read-totalcontainspictureandviewing, so don't sum them. - Budget test: the median of three warm
app;durvalues fromServer-Timing, at 500 posts, stays under 50 ms. - Scope: header-only, with no markup, input or write path touched.
To try it, open / signed in and read Server-Timing.
GET /now carriesreadandrenderphases in itsServer-Timingheader. A new test holds it to 50 ms with 500 posts. I ranfeed-budget,home-timing,home-feed-budget,front-door-timing,route-timing-coverageandmcp-size: all pass, andtscis clean. I did not run the full suite; the forge runs it on the push./already reportedsession,picture,viewingandrenderbut noread.src/web/pages/home_flow.tsnow adds areadphase that covers the whole read stretch (pictureplusviewing). The finer phases stay beside it.test/feed-budget.test.tsalready held/feedto the 500-post budget. I added two tests there for/: one checks thatreadandrenderappear inServer-Timing, the other checks that the median of three warm answers is under 50 ms. The median uses the existingmedianhelper fromtest/helpers/page_budget.ts./was already under budget at 500 posts (and its app phase is checked at 5,000 inhome-feed-budget), so I added no index or limit.src/feed/. I did not touch the MCP, somcp-sizeis unchanged and its ceilings stay as they were. The new tests are in an existing file, so there was nothing to add toscripts/gate.ts.The push hook asked for a "Try:" commit, so the second commit is an empty one for that.
How to try it: sign in, then
curl -si -H "cookie: forge_session=…" /and readServer-Timing. Or runbun test test/feed-budget.test.ts.Closes #15766