Skip to content

abso-core

Public

abso is version control for agents: the client, the engine and a server you can run on your own Cloudflare account.

Check passed

Versions 253 to 318

Compare

+37 −2 in 2 places
Lines 66–83 at 318 (were 66–77 at 253)
6666 const p = space.versions[v]!;
6767 if (![...p.atoms, ...(p.dropped ?? [])].some((id) => g.filesOf(id).some((f) => sources.has(f)))) continue;
6868 }
69+ // With a path: only the versions that changed that file (its history), under its name then. Their files first, and
70+ // the whole entry (every atom of the version read) only for those (abso Capacity): a file's history read every
71+ // version's atoms down to its twentieth change.
72+ if (path !== undefined && !host.paths.versionFiles(space, v, views).includes(nameAt(v))) {
73+ views.delete(v + 1);
74+ continue;
75+ }
6976 const entry = logEntry(host, space, v, views);
7077 // The walk goes down: a view above this version won't be needed again (#46).
7178 views.delete(v + 1);
72− // With a path: only the versions that changed that file (its history), under its name then.
7379 if (path === undefined) versions.push(entry);
74− else if (entry.files.includes(nameAt(v))) versions.push(nameAt(v) === path ? entry : { ...entry, path: nameAt(v) });
80+ else versions.push(nameAt(v) === path ? entry : { ...entry, path: nameAt(v) });
7581 }
7682 const next = v >= 0 && versions.length > 0 ? versions[versions.length - 1]!.version : undefined;
7783 const movedFrom = names.slice(0, -1).map((n, i) => ({ path: names[i + 1]!.path, version: n.since }));
Lines 244–278 at 318 (were 238–243 at 253)
238244 };
239245}
240246
247+/**
248+ * fileAt for exactly this spelling, from the file's own lines (abso Capacity, 2026-10-17): no spelling lookup and no
249+ * list of the version's files. fileAt's hasFile answers from the version's whole path list, folded from version 0
250+ * when nothing's kept, and a spelling it doesn't find reads every known path. A name nothing ever wrote is one read.
251+ * The pipeline's project files (abso.yml and the like) are read this way on every tick.
252+ */
253+export function fileExactAt(
254+ host: LogHost,
255+ path: string,
256+ version: number,
257+ options: { draft?: string | null; agent?: string } = {},
258+): { path: string; version: number; text: string | null; blob?: string } {
259+ host.needInit();
260+ checkReadPath(path);
261+ const space = host.spaceFor(options);
262+ host.checkVersion(space, version);
263+ if (!host.graph.hasAtomsIn(path)) return { path, version, text: null };
264+ const view = host.viewAt(space, version);
265+ const attrs = view.attrs(path);
266+ // hasFile's own test, without its path list: kept while empty, a link, a binary, or a visible line.
267+ const exists = attrs.exists || attrs.link !== null || attrs.blob !== null || view.lines(path).length > 0;
268+ return {
269+ path,
270+ version,
271+ text: exists ? view.text(path) : null,
272+ ...(attrs.blob !== null ? { blob: attrs.blob } : {}),
273+ };
274+}
241276/** The files that may differ between two versions, and both views: compare's and compareSummary's ground. */
242277function compared(
243278 host: LogHost,
MCP
compare on this site's /mcp
CLI
abso diff 253 318 worker/project/version-log.ts --json
JSON
/christopher/abso-core/compare/253..318?file=worker%2Fproject%2Fversion-log.ts&format=json