Public: anyone can read this; the crew can change it.

A stopped release shows its one cause and one action on the owner's board, from the keeper's last beat #15472

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

mason/forge:mason/15469-a-stopped-release-shows-its-one-cause-an → main 0 commits fork 2 threads · 2 unresolved

  • Merged. mason/15469-a-stopped-release-shows-its-one-cause-an was merged into main as 1e36e93.

Review

Sign in to review this change.
12 files changed +207 −20
docs/OPERATING.md +1 −1
@@ -288,7 +288,7 @@ once each has held five minutes, and says Recovered once it has been gone five
288288 paged. Every other cause (`drill`, `mirror`, `stuck:*`, `red:*`, `snapshots`,
289289 `budget:*`) is paged elsewhere or is a setting, and is ignored here.
290290
291 Releases stopped at v0.7.629 (cab90cf, 2026-11-20) with main green since (#15443); the cause is unconfirmed (#15448). Read on 2026-11-22 (#15454): no tag after v0.7.629 exists, so the release workflow never ran and the stop is in the cut, before it. The check of main's head `45635e4` is `ok`, so a red main does not hold the cut. The keeper's reason could not be read: the crew token's `GET /api/v1/keeper` (#15451) answers 404 because production runs v0.7.629, which predates that read. The one unblocking action is the owner's: read `blocked`, `heartbeat` and holds on `/releases` or `GET /api/v1/keeper` with an admin token, then lift the hold or fix what the reason names. The next release, whatever cuts it, ships #15451, so the crew can read the keeper from then on. `release_now` still waits on a hold and on disk room, so it does not get around the cause. The main-ahead alarm now falls back to main's checks and, when production's commit has no check row here, to main's commits past the newest release tag (#15467), naming the gap in commits and the days since that tag; it stays silent while `release.ahead_minutes` exceeds the wait, and with no release tag at all.
291 Releases stopped at v0.7.629 (cab90cf, 2026-11-20) with main green since (#15443); the cause is unconfirmed (#15448). Read on 2026-11-22 (#15454): no tag after v0.7.629 exists, so the release workflow never ran and the stop is in the cut, before it. The check of main's head `45635e4` is `ok`, so a red main does not hold the cut. The keeper's reason could not be read: the crew token's `GET /api/v1/keeper` (#15451) answers 404 because production runs v0.7.629, which predates that read. The one unblocking action is the owner's: read `blocked`, `heartbeat` and holds on `/releases` or `GET /api/v1/keeper` with an admin token, then lift the hold or fix what the reason names. The next release, whatever cuts it, ships #15451, so the crew can read the keeper from then on. `release_now` still waits on a hold and on disk room, so it does not get around the cause. A stopped release now says itself on the board, the terminal and `release_keeper` (#15469); how to read it and its actions are in docs/features/release-keeper.md. The main-ahead alarm now falls back to main's checks and, when production's commit has no check row here, to main's commits past the newest release tag (#15467), naming the gap in commits and the days since that tag; it stays silent while `release.ahead_minutes` exceeds the wait, and with no release tag at all.
outdated

Put the how-to for the stopped-release sentence in docs/features/release-keeper.md (or release-heartbeat.md); OPERATING.md keeps only the operating note.

292292
293293 ## A release proves itself
294294
docs/features/release-keeper.md +29 −1
@@ -116,10 +116,38 @@ measured is left out. They show under the release on `/releases` and in
116116 `release_keeper` (`stages`), which also answers `holding` (what the tick last
117117 said stopped it: the disk guard, the spacing, a snapshot) and `releaseNow`.
118118
119 ## A stopped release says why (#15469)
120
121 When main has been past the newest release tag for over 26 hours (the
122 release tick's day plus two hours) and the keeper's last beat is silent,
123 skipped or failed, one sentence says so:
124
125 > No release since v0.7.629 (2026-11-20 14:02 UTC) while main is 31 commits
126 > ahead: the keeper skipped: disk below the floor. Next: fix what the reason
127 > names; the next tick cuts.
128
129 It names the newest tag and when it was cut, main's commits past it, why (the
130 tick has never reported, has not reported for a span, or the beat's skipped or
131 failed reason) and the one action:
132
133 - the tick is silent or never reported: **start the host timer
134 forge-release-tick**;
135 - an owner hold stands: **lift the hold on /releases**;
136 - a failed release's hold stands: **land the fix in a pull saying
137 "release hold N", or lift the hold on /releases**;
138 - otherwise: **fix what the reason names; the next tick cuts**.
139
140 The same sentence is the one `release:behind` card on the owner's board
141 (linking to `/releases`, in place of the "production is behind" line), the
142 first line of the terminal's **Release keeper** screen, and `stopped` in MCP
143 `release_keeper` and `GET /api/v1/keeper` (null while releases flow). A cut
144 tag clears it everywhere.
145
119146 ## Where to see it
120147
121148 - The terminal: **Release keeper** in the command palette shows the same
122 read as the card, for the same people.
149 read as the card, for the same people, opening with a stopped release's
150 sentence when there is one.
123151 - `/releases`: the **Release keeper** card says what holds the next cut and
124152 lists each release with its stage, the known-good version, the roll's
125153 non-200s, the probes and pages, the worst latency and the seconds dark.
src/flow/alarm_main_ahead.ts +2 −2
@@ -14,7 +14,7 @@ import { neverTickedLine, outsideDependencies } from "../keeper/at_boot.ts";
1414 import { agoWords, lastBeat } from "../keeper/beat.ts";
1515 import { ownRepoPath } from "../kernel/own_repo.ts";
1616 import { running } from "../kernel/version.ts";
17 import { tagAhead } from "../release/behind.ts";
17 import { newestStanding } from "../release/behind.ts";
1818 import { waitingKeys, waitingRows } from "../release/landings.ts";
1919
2020 export const AHEAD_SETTING = "release.ahead_minutes";
@@ -91,7 +91,7 @@ function checkedSince(
9191 * store: the count, when the oldest was committed (ISO), the tag's version and when it was cut.
9292 */
9393 function tagGap(): { readonly since: string; readonly commits: number; readonly version: string; readonly at: number } | undefined {
94 const newest = tagAhead();
94 const newest = newestStanding();
9595 const ahead = newest?.ahead;
9696 if (newest === undefined || ahead === undefined || ahead.commits < 1) return undefined;
9797 return { since: new Date(ahead.since).toISOString(), commits: ahead.commits, version: newest.version, at: newest.at };
src/http/mcp/tools/release_keeper.ts +1 −1
@@ -4,7 +4,7 @@ import { bad, good, type Tool } from "../shared.ts";
44
55 export const tool: Tool = {
66 name: "release_keeper",
7 doc: "`{}`: what the release keeper (#7557) did: its releases newest first (version, commit (short sha), stage — rolling, verifying, verified or rolled_back —, the known-good version it would roll back to, roll probes and non-200s, probes and pages under load, worst ms, seconds dark, reason, landedToLiveSeconds — from the merge of its pull to the new version answering, null until it has (#8042), interruptedRuns — the crew runs the drained process still had running at the switch, null when not counted (#11917), writePauseMs — how long the new forge held its queue work at boot, null when not measured; the next cut waits 10× it, #7836) and its holds (kind failed or owner, version, reason, probe numbers, the pull that said `release hold N`, lifted); `blocked` says what stops the next cut; `heartbeat` is the release tick's last report (at, outcome cut/skipped/failed, reason, silent when over an hour old, #11507); for whoever may read /releases",
7 doc: "`{}`: what the release keeper (#7557) did: its releases newest first (version, commit (short sha), stage — rolling, verifying, verified or rolled_back —, the known-good version it would roll back to, roll probes and non-200s, probes and pages under load, worst ms, seconds dark, reason, landedToLiveSeconds — from the merge of its pull to the new version answering, null until it has (#8042), interruptedRuns — the crew runs the drained process still had running at the switch, null when not counted (#11917), writePauseMs — how long the new forge held its queue work at boot, null when not measured; the next cut waits 10× it, #7836) and its holds (kind failed or owner, version, reason, probe numbers, the pull that said `release hold N`, lifted); `blocked` says what stops the next cut; `stopped`: why main sits a day past the newest tag, and the one action (#15469); `heartbeat` is the release tick's last report (at, outcome cut/skipped/failed, reason, silent when over an hour old, #11507); for whoever may read /releases",
88 description: "The release keeper's releases, holds and what blocks the next cut.",
99 inputSchema: { type: "object", properties: {} },
1010 writes: false,
src/keeper/hold.ts +6 −1
@@ -82,9 +82,14 @@ export function standingHolds(db: Database): Hold[] {
8282 return db.query<Row, []>(`SELECT * FROM keeper_hold WHERE lifted_at IS NULL ORDER BY id`).all().map(toHold);
8383 }
8484
85 /** The hold that stops the next cut: the owner's, or a failed verify whose cause has not landed. */
86 export function blockingHold(holds: readonly Hold[]): Hold | undefined {
87 return holds.find((x) => x.kind === "owner" || x.causePull === null);
88 }
89
8590 /** What stops a cut, in one line; undefined when nothing does. A failed hold whose cause has landed lets the fix through. */
8691 export function blocking(holds: readonly Hold[]): string | undefined {
87 const h = holds.find((x) => x.kind === "owner" || x.causePull === null);
92 const h = blockingHold(holds);
8893 if (h === undefined) return undefined;
8994 return h.kind === "owner"
9095 ? `the owner holds releases: ${h.reason}`
src/keeper/landed.ts +44 −3
@@ -7,8 +7,9 @@
77 */
88
99 import type { Database } from "bun:sqlite";
10 import { beatLine, lastBeat, SILENT_MS, type Beat } from "./beat.ts";
11 import { blocking, listHolds, standingHolds, type Hold } from "./hold.ts";
10 import { newestStanding, type Newest } from "../release/behind.ts";
11 import { agoWords, beatLine, lastBeat, SILENT_MS, type Beat } from "./beat.ts";
12 import { blocking, blockingHold, listHolds, standingHolds, type Hold } from "./hold.ts";
1213 import { pendingNow, type NowRequest } from "./now.ts";
1314 import { listKeeperReleases, type KeeperRelease } from "./record.ts";
1415
@@ -113,16 +114,56 @@ export function heartbeatOf(db: Database, now: Date = new Date()): Heartbeat | n
113114 return { ...beat, silent: now.getTime() - Date.parse(beat.at) > SILENT_MS, says: beatLine(beat, now) };
114115 }
115116
117 /** "2026-11-20 10:30 UTC". */
118 const utcMinute = (ms: number): string => `${new Date(ms).toISOString().slice(0, 16).replace("T", " ")} UTC`;
119
120 /**
121 * A stopped release as one sentence (#15469): main has been past the newest tag for longer than
122 * {@link SILENT_MS} and the keeper's last beat is silent, skipped or failed. It says since when,
123 * the beat's reason and the one action; undefined while there is no tag, main is not ahead, or
124 * the keeper's last beat is a fresh cut. The board's `release:behind` card, the terminal's first
125 * screen and MCP `release_keeper`'s `stopped` all say these words, and a tag cut clears it.
126 */
127 export function stoppedRelease(db: Database, newest: Newest | undefined, now: Date = new Date()): string | undefined {
128 const ahead = newest?.ahead;
129 if (newest === undefined || ahead === undefined || ahead.commits < 1) return undefined;
130 const t = now.getTime();
131 if (!(t - ahead.since > SILENT_MS)) return undefined;
132 const beat = lastBeat(db);
133 const silent = beat === null || t - Date.parse(beat.at) > SILENT_MS;
134 if (!silent && beat.outcome === "cut") return undefined;
135 const commits = `${ahead.commits} ${ahead.commits === 1 ? "commit" : "commits"}`;
136 const head = `No release since ${newest.version} (${utcMinute(newest.at)}) while main is ${commits} ahead`;
137 const why =
138 beat === null
139 ? "the release tick has never reported"
140 : silent
141 ? `the release tick has not reported for ${agoWords(t - Date.parse(beat.at)).replace(" ago", "")}`
142 : `the keeper ${beat.outcome === "failed" ? "failed" : "skipped"}: ${beat.reason}`;
143 const hold = blockingHold(standingHolds(db));
144 const action = silent
145 ? "start the host timer forge-release-tick"
146 : hold === undefined
147 ? "fix what the reason names; the next tick cuts"
148 : hold.kind === "owner"
149 ? "lift the hold on /releases"
150 : `land the fix in a pull saying "release hold ${hold.id}", or lift the hold on /releases`;
151 return `${head}: ${why.replace(/[.\s]+$/, "")}. Next: ${action}.`;
152 }
153
116154 /** What the keeper did and what stops the next cut: one answer for MCP `release_keeper` and `GET /api/v1/keeper`. */
117155 export function keeperAnswer(
118156 db: Database,
119157 now: Date = new Date(),
120 ): { blocked: string | null; holding: string | null; releaseNow: NowRequest | null; releases: LandedRelease[]; holds: Hold[]; heartbeat: Heartbeat | null } {
158 newest: Newest | undefined = newestStanding(),
159 ): { blocked: string | null; holding: string | null; stopped: string | null; releaseNow: NowRequest | null; releases: LandedRelease[]; holds: Hold[]; heartbeat: Heartbeat | null } {
121160 const heartbeat = heartbeatOf(db, now);
122161 return {
123162 blocked: blocking(standingHolds(db)) ?? null,
124163 // What the tick last said stopped it (the disk guard, the spacing, a snapshot): visible, not only in a log (#11839).
125164 holding: heartbeat !== null && heartbeat.outcome === "skipped" && !heartbeat.silent ? heartbeat.reason : null,
165 // No release for a day past main moving: the board's card, in its words (#15469).
166 stopped: stoppedRelease(db, newest, now) ?? null,
126167 releaseNow: pendingNow(db, now.getTime()) ?? null,
127168 releases: withLandedToLive(db, listKeeperReleases(db)),
128169 holds: listHolds(db),
src/kernel/vitals.ts +8 −2
@@ -41,7 +41,8 @@ import { drillNeed, lastVerdict } from "../snapshot/verdict.ts";
4141 import { leftoverProbes, PROBE_NAME, proofNeed, proofNotice } from "../release/prove.ts";
4242 import { running as runningVersion } from "./version.ts";
4343 import { rollbackNeed } from "../release/launch.ts";
44 import { behindStanding } from "../release/behind.ts";
44 import { behindStanding, newestStanding } from "../release/behind.ts";
45 import { stoppedRelease } from "../keeper/landed.ts";
4546 import { newestDrills } from "../core/domain_drills.ts";
4647 import { capacityValue, machineLimits, podMemoryUsedBytes, type MachineLimits } from "../core/capacity.ts";
4748 import { memoryLimitBytes } from "../system/memory_limit.ts";
@@ -720,8 +721,13 @@ export function vitals(input: VitalsInput): Vitals {
720721
721722 // Production serving a version older than a release main has had over an hour is a card until
722723 // they match.
724 // Main a day past the newest tag with the keeper silent, skipping or failing is the same one
725 // card, saying why and the one action (#15469).
723726 const lagging = behindStanding(now);
724 if (lagging !== undefined) need("todo", "release:behind", `${lagging.sentence}.`, lagging.since, "/board");
727 const newest = newestStanding();
728 const stopped = stoppedRelease(input.db, newest, new Date(now));
729 if (stopped !== undefined) need("todo", "release:behind", stopped, new Date(newest?.ahead?.since ?? now).toISOString(), "/releases");
outdated

ahead !== undefined && stopped !== undefined is redundant: stoppedRelease already returns undefined when ahead is absent, and ahead is only used for since. Compute stopped directly, and derive the since from newestStanding()?.ahead inside the branch, so there is one check.

730 else if (lagging !== undefined) need("todo", "release:behind", `${lagging.sentence}.`, lagging.since, "/board");
725731
726732 // Lines recorded and not landed for five minutes: the writer is failing, however quiet the site.
727733 const quiet = unwrittenFor(now);
src/release/behind.ts +5 −4
@@ -172,10 +172,11 @@ export function behindStanding(now: number): BehindNeed | undefined {
172172 }
173173
174174 /**
175 * The newest release tag and main's commits past it, from the watch's last read (#15467): the
176 * main-ahead flow alarm's fallback when production's commit has no check row. Undefined with no
177 * watch set or no tag, so a fresh forge or a fork with no tags stays quiet.
175 * The newest release tag and main's commits past it, from the watch's last read: the stopped
176 * release's sentence (#15469) and the main-ahead flow alarm's fallback when production's commit has
177 * no check row (#15467). Undefined with no watch set or no tag, so a fresh forge or a fork with no
178 * tags stays quiet.
178179 */
179 export function tagAhead(): Newest | undefined {
180 export function newestStanding(): Newest | undefined {
180181 return current?.newest();
181182 }
src/tui/screens/keeper.ts +10 −1
@@ -16,7 +16,8 @@ import { beatLine, lastBeat } from "../../keeper/beat.ts";
1616 import { stallWords } from "../../perf/boot_stall.ts";
1717 import { blocking, holdAs, liftAs, standingHolds } from "../../keeper/hold.ts";
1818 import { pauseWords } from "../../keeper/pause.ts";
19 import { secondsWords, withLandedToLive, type LandedRelease } from "../../keeper/landed.ts";
19 import { secondsWords, stoppedRelease, withLandedToLive, type LandedRelease } from "../../keeper/landed.ts";
20 import { newestStanding } from "../../release/behind.ts";
2021 import { releaseNowAs, pendingNow } from "../../keeper/now.ts";
2122 import { listKeeperReleases, type Stage } from "../../keeper/record.ts";
2223 import { mayRead, mayRollBack } from "../../release/gate.ts";
@@ -46,6 +47,11 @@ export interface KeeperRead {
4647 readonly heartbeat: string;
4748 /** Main green and ahead of production, and for how long; absent when it is not. */
4849 readonly ahead?: string;
50 /**
51 * A stopped release: since when, why and the one action, the board's card (#15469); absent while
52 * releases flow.
53 */
54 readonly stopped?: string;
4955 /** A standing release-now request, said plainly; absent when there is none. */
5056 readonly asked?: string;
5157 readonly releases: readonly LandedRelease[];
@@ -59,7 +65,9 @@ export function readKeeper(f: Session, now: Date = new Date()): KeeperRead | und
5965 const beat = lastBeat(f.db);
6066 // Never heard from: the same keeper line /releases and the main-ahead alarm name (#11924).
6167 const never = beat === null ? neverTickedLine() : undefined;
68 const stopped = stoppedRelease(f.db, newestStanding(), now);
6269 return {
70 ...(stopped === undefined ? {} : { stopped }),
6371 blocked: blocking(standingHolds(f.db)) ?? "Nothing holds the next cut.",
6472 heartbeat: never === undefined ? beatLine(beat, now) : `${beatLine(beat, now)} ${never[0]!.toUpperCase()}${never.slice(1)}.`,
6573 ...(ahead === undefined ? {} : { ahead }),
@@ -125,6 +133,7 @@ export function keeperScreen(f: Session, ctx: Ctx): Screen {
125133 // What holds the cut ends with what to land ("release hold N"): wrapped, up to three lines,
126134 // never cut short of it.
127135 const lines = [
136 ...(read.stopped === undefined ? [] : wrap(read.stopped, area.w).slice(0, 3)),
128137 ...wrap(read.blocked, area.w).slice(0, 3),
129138 ...wrap(read.heartbeat, area.w).slice(0, 2),
130139 ...(read.ahead === undefined ? [] : wrap(read.ahead, area.w).slice(0, 2)),
test/keeper-landed-doors.test.ts +96 −2
@@ -4,14 +4,20 @@
44 * figure from `keeper/landed.ts`. Pull 7 merged at noon; the keeper cut at
55 * once, and 0.7.284 answered 42 s later, so each door says 42 s.
66 */
7 import { describe, expect, test } from "bun:test";
7 import { afterEach, describe, expect, test } from "bun:test";
8 import { forgeNeedList, needTermLine } from "../src/actions/health.ts";
9 import { vitals } from "../src/kernel/vitals.ts";
10 import { recordBeat } from "../src/keeper/beat.ts";
11 import { setHold } from "../src/keeper/hold.ts";
12 import { setBehind, watchBehind, type Newest } from "../src/release/behind.ts";
813 import type { Ctx as HttpCtx } from "../src/http/context.ts";
914 import { tool as keeperTool } from "../src/http/mcp/tools/release_keeper.ts";
1015 import { tick } from "../src/keeper/keeper.ts";
1116 import type { LandedRelease } from "../src/keeper/landed.ts";
1217 import type { User } from "../src/core/users.ts";
1318 import { createForgeApp } from "../src/tui/forge.ts";
14 import { keeperScreen } from "../src/tui/screens/keeper.ts";
19 import { dashboardScreen } from "../src/tui/screens/dashboard.ts";
20 import { keeperScreen, readKeeper } from "../src/tui/screens/keeper.ts";
1521 import { headlessTerminal } from "../src/tui/term/terminal.ts";
1622 import { keeperPanel } from "../src/web/pages/keeper-panel.ts";
1723 import { quietLogs } from "./helpers/globals.ts";
@@ -66,3 +72,91 @@ describe("landed to live at every door", () => {
6672 expect(card).toContain("<td>42 s</td>");
6773 });
6874 });
75
76 /**
77 * A stopped release at every door (#15469): main 369 commits and 30 h past 0.7.629, the keeper's
78 * last beat a skip 2 h ago behind the owner's hold. The board's one `release:behind` card, the
79 * terminal's first screen and MCP `release_keeper`'s `stopped` say one sentence, and a tag cut
80 * clears it.
81 */
82 describe("a stopped release says its cause and its action", () => {
83 const H = 3_600_000;
84 afterEach(() => setBehind(undefined));
85
86 /** The forge with the behind watch reading `newest`, ticked once. */
87 async function stoppedForge(newest: Newest | undefined) {
88 const f = await keeperForge();
89 const now = Date.now();
90 const read = { newest };
91 const watch = watchBehind({ live: () => "0.7.629", read: async () => read.newest });
92 setBehind(watch);
93 await watch.tick();
94 recordBeat(f.app.db, "skipped", "the owner holds releases: disk swap", new Date(now - 2 * H));
95 return { f, now, read, watch };
96 }
97 const ahead = (now: number): Newest => ({ version: "0.7.629", at: now - 40 * H, ahead: { commits: 369, since: now - 30 * H } });
98 const card = (f: Awaited<ReturnType<typeof keeperForge>>) =>
99 vitals({ db: f.app.db, signals: f.app.signals, dataDir: f.app.config.dataDir, now: Date.now() }).degraded.filter((d) => d.cause.startsWith("release:"));
100 const mcpStopped = async (f: Awaited<ReturnType<typeof keeperForge>>) => {
101 const read = await keeperTool.run({ app: f.app } as unknown as HttpCtx, f.user, {});
102 if (!read.ok) throw new Error("release_keeper refused an admin");
103 return (read.value as { stopped: string | null }).stopped;
104 };
105
106 test("one card names since when, the beat's reason and the one action, and MCP says the same words", async () => {
107 const { f, now, watch, read } = await stoppedForge(undefined);
108 read.newest = ahead(now);
109 await watch.tick();
110 setHold(f.app.db, { kind: "owner", version: "0.7.629", reason: "disk swap", at: now - 28 * H });
111 const at = new Date(now - 40 * H).toISOString().slice(0, 16).replace("T", " ");
112 const sentence = `No release since 0.7.629 (${at} UTC) while main is 369 commits ahead: the keeper skipped: the owner holds releases: disk swap. Next: lift the hold on /releases.`;
113 const cards = card(f);
114 expect(cards).toHaveLength(1);
115 expect(cards[0]).toMatchObject({ cause: "release:behind", sentence, href: "/releases" });
116 expect(await mcpStopped(f)).toBe(sentence);
117 // The terminal's first screen prints the board's forge needs.
118 expect(forgeNeedList(f.app, f.user)!.map(needTermLine).filter((l) => l.startsWith(sentence))).toHaveLength(1);
119 const terminal = headlessTerminal(400, 60);
120 const { app: tui, session } = createForgeApp(f.app, identity(f.user), { terminal, exitHooks: false });
121 tui.start();
122 tui.ctx.push(dashboardScreen(session, tui.ctx));
123 await settleApp(tui);
124 const text = tui.screen.toText();
125 tui.stop?.();
126 expect(text).toContain("No release since 0.7.629");
127 // The terminal's Release keeper leads with it too.
128 expect(readKeeper(session)?.stopped).toBe(sentence);
129 });
130
131 test("a silent tick and a failed one each name their own action", async () => {
132 const { f, now, watch, read } = await stoppedForge(undefined);
133 read.newest = ahead(now);
134 await watch.tick();
135 recordBeat(f.app.db, "failed", "tag v0.7.630 refused: permission denied", new Date(now - 2 * H));
136 expect(await mcpStopped(f)).toEndWith(": the keeper failed: tag v0.7.630 refused: permission denied. Next: fix what the reason names; the next tick cuts.");
137 f.app.db.query("DELETE FROM keeper_beat_tick").run();
138 expect(await mcpStopped(f)).toEndWith(": the release tick has never reported. Next: start the host timer forge-release-tick.");
139 recordBeat(f.app.db, "cut", "cut 0.7.630", new Date(now - 30 * H));
140 expect(await mcpStopped(f)).toEndWith(": the release tick has not reported for 30 h 0 min. Next: start the host timer forge-release-tick.");
141 });
142
143 test("a tag cut clears it, and no tag or main not ahead is no card", async () => {
144 const { f, now, watch, read } = await stoppedForge(undefined);
145 expect(card(f)).toHaveLength(0);
146 expect(await mcpStopped(f)).toBeNull();
147 read.newest = ahead(now);
148 await watch.tick();
149 expect(card(f)).toHaveLength(1);
150 // Main ahead for less than a day and two hours is the behind card's own words, not this one.
151 read.newest = { version: "0.7.629", at: now - 40 * H, ahead: { commits: 3, since: now - 20 * H } };
152 await watch.tick();
153 expect(card(f).map((d) => d.sentence)).toEqual(["production is 0.7.629; main is 3 commits ahead, 20 h."]);
154 expect(await mcpStopped(f)).toBeNull();
155 // The keeper cuts 0.7.630 at main's tip: main is not ahead, and the card is gone.
156 read.newest = { version: "0.7.630", at: now };
157 await watch.tick();
158 expect(card(f)).toHaveLength(0);
159 expect(await mcpStopped(f)).toBeNull();
160 expect(readKeeper({ app: f.app, db: f.app.db, user: f.user } as unknown as Parameters<typeof readKeeper>[0])?.stopped).toBeUndefined();
161 });
162 });
test/kernel-boundary.test.ts +1
@@ -40,6 +40,7 @@ const CROSSINGS: Readonly<Record<string, string>> = {
4040 "vitals.ts -> ../release/prove.ts": "the standing names leftover release probes",
4141 "vitals.ts -> ../release/launch.ts": "the standing asks for a rollback when one is due",
4242 "vitals.ts -> ../release/behind.ts": "the standing says when production is behind main",
43 "vitals.ts -> ../keeper/landed.ts": "the standing says why a release stopped and the one action",
4344 "vitals.ts -> ../core/domain_drills.ts": "the standing reports the newest domain drills",
4445 "vitals.ts -> ../core/capacity.ts": "the standing reads the machine's limits and use",
4546 "vitals.ts -> ../system/memory_limit.ts": "the standing reads the memory limit",
test/llms-budget.test.ts +4 −2
@@ -46,9 +46,11 @@ const get = async (token?: string): Promise<string> =>
4646 * Raised at #14429: signed-in 80,129 and admin 91,562 after the route catalogue grew
4747 * (#14423-#14425). Raised again: signed-in 80,570, admin 92,108 after the routes of #14570 and
4848 * #14531 (feed count, app filter). Raised at #14889: signed-in 80,797 and admin 92,230 (anonymous
49 * 9,033, unchanged) on main after that; ceilings are those sizes plus about a percent.
49 * 9,033, unchanged) on main after that; ceilings are those sizes plus about a percent. Raised at
50 * #15469: signed-in 81,436 and admin 93,149 (anonymous 9,033) once release_keeper documents
51 * `stopped`; main had grown to within 22 bytes of the admin ceiling.
5052 */
51 const BUDGET = { anonymous: 9_100, signedIn: 81_600, admin: 93_100 } as const;
53 const BUDGET = { anonymous: 9_100, signedIn: 82_300, admin: 94_100 } as const;
5254
5355 test("/llms.txt stays under its byte budget for each role", async () => {
5456 const sizes = {

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs