···2929 config: BackfillConfig
3030}
31313232-3332interface PdsResolution {
3433 /** The PDS service endpoint URL from the DID document. */
3534 pds: string
···8281 return result
8382}
84838585-8684/**
8785 * Paginates through all active repos on a relay/PDS using `com.atproto.sync.listRepos`.
8886 * Yields `{ did, rev }` for each active repo. Skips deactivated repos.
···128126 cursor = data.cursor
129127 }
130128}
131131-132129133130/**
134131 * Downloads and indexes a single user's repo via `com.atproto.sync.getRepo`.
···307304 }
308305}
309306310310-311307/**
312308 * Processes items concurrently with a fixed number of workers.
313309 * Workers pull from a shared index so the pool stays saturated even when
···335331 const workers = Array.from({ length: Math.min(parallelism, items.length) }, () => worker())
336332 await Promise.all(workers)
337333}
338338-339334340335/**
341336 * Orchestrates a full backfill run: enumerate repos, filter to pending, download, and index.
+1-1
packages/hatk/src/car.ts
···125125 async function fill(need: number): Promise<boolean> {
126126 while (len - pos < need) {
127127 const { done, value } = await reader.read()
128128- if (done) return (len - pos) >= need
128128+ if (done) return len - pos >= need
129129 byteLength += value.length
130130131131 // Compact: shift remaining data to front when read cursor passes midpoint
···15541554 const rows = await all(`SELECT did FROM _repos WHERE did IN (${placeholders}) AND status = 'takendown'`, ...dids)
15551555 return new Set(rows.map((r: any) => r.did))
15561556}
15571557-