commit dae773bfc92692452967156f8f94abb5adb5f566
parent 0b9e8c4e5257a0ee882328452462b11f27f38802
Author: I Mean I'm Just Saying <imeanimjustsaying@kiwifarms.st>
Date: Mon, 2 Nov 2026 03:41:12 -0500
umtool: source backlog -- the editor read fresh, the line in the Overview's right column
A read of the backlog asks the editor fresh (askEditor keeps a GET 2 s: a read right after a
change of counts or Prioritize saw the old answer, and a watch did not fire). The line sits
under "This video" in the right column, so the decisions on the left keep their place. The
spec reads the fixture from umtool/.e2e-song.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Diffstat:
3 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/umtool/components/projects/report/OverviewTab.tsx b/umtool/components/projects/report/OverviewTab.tsx
@@ -56,9 +56,6 @@ export default async function OverviewTab({ project, detail, frame }: ReportTabP
<NextCard pieceId={frame.pieceId} title={frame.piece?.title ?? project.id} lifecycle={frame.lifecycle} />
</Suspense>
- {/* How much of each cited channel the archive holds and has transcribed (UI notes item 16). */}
- {clips.length > 0 && <SourceBacklog project={project.id} />}
-
<div className="grid grid-cols-1 gap-[22px] lg:grid-cols-[minmax(0,1.25fr)_minmax(0,1fr)]">
<div className="min-w-0 space-y-4">
{/* --- what is wrong, first ------------------------------------- */}
@@ -121,6 +118,9 @@ export default async function OverviewTab({ project, detail, frame }: ReportTabP
</ul>
</section>
+ {/* How much of each cited channel the archive holds and has transcribed (UI notes item 16). */}
+ {clips.length > 0 && <SourceBacklog project={project.id} />}
+
{frame.board && (
<section data-piece-board={frame.board.id}>
<h2 className="micro mb-1.5">Research board</h2>
diff --git a/umtool/e2e/source-backlog.spec.ts b/umtool/e2e/source-backlog.spec.ts
@@ -21,7 +21,7 @@ import { portFor } from "yt-dlp-transcript-common/lib/ports.mjs";
// ---------------------------------------------------------------------------
const HERE = path.dirname(fileURLToPath(import.meta.url));
-const FIXTURE = path.join(HERE, ".e2e-song");
+const FIXTURE = path.join(HERE, "..", ".e2e-song");
const DIR = path.join(FIXTURE, "reports", "source-backlog-fixture");
const PROJECT = "reports/source-backlog-fixture";
const STUB_LOG = path.join(FIXTURE, "editor-stub.requests.json");
diff --git a/umtool/lib/report/sourceBacklog.ts b/umtool/lib/report/sourceBacklog.ts
@@ -22,7 +22,8 @@ export async function readBacklog(dir: string, manifest: Record<string, unknown>
const m = (manifest ?? (await readManifest(dir)) ?? {}) as Record<string, unknown>;
const cited = citedChannels(m) as { slug: string; clips: number }[];
let editorError: string | null = null;
- const focus = await askEditor<{ value?: { focus?: unknown } }>("/api/ops/settings?key=channelPriority")
+ // Fresh: a read right after Prioritize or a change of counts must see it (askEditor keeps a GET 2 s).
+ const focus = await askEditor<{ value?: { focus?: unknown } }>("/api/ops/settings?key=channelPriority", { fresh: true })
.then((r) => r.value?.focus ?? null)
.catch((e: unknown) => {
editorError = e instanceof Error ? e.message : String(e);
@@ -32,7 +33,7 @@ export async function readBacklog(dir: string, manifest: Record<string, unknown>
const channels: BacklogRow[] = await Promise.all(
cited.map(async ({ slug, clips }) => {
try {
- const r = await askEditor(`/api/ops/channel/${encodeURIComponent(slug)}`);
+ const r = await askEditor(`/api/ops/channel/${encodeURIComponent(slug)}`, { fresh: true });
return { ...(backlogOf(slug, r) as ReturnType<typeof backlogOf>), clips, focused: inFocus.has(slug) };
} catch (e) {
if (!(e instanceof EditorError) || e.status !== 404) editorError ??= e instanceof Error ? e.message : String(e);