Handle large WeebCentral catalogs and correct MangaPill checkpoint monitoring

This commit is contained in:
Codex committed 2026-10-14 14:01:05 +02:00
1 parent 0d51f214d5
commit edbc9c6056
11 files changed
+102 -7

No files matched your search

+3
View File
@@ -36,6 +36,9 @@ class Monitor {
const ids = new Set();
for (const entry of scraper.active || []) {
const id = entry.current.id; ids.add(id);
// Without a checkpoint, a null progress key stays constant forever and
// cannot prove a stall. Do not quarantine a live worker on that basis.
if (!entry.job) { this.observations.delete(id); this.resolve(`stall:${id}`); continue; }
const key = progressKey(entry.job), prior = this.observations.get(id);
if (!prior || prior.key !== key) { this.observations.set(id, { key, at: now }); this.resolve(`stall:${id}`); continue; }
if (scraper.paused || scraper.sourcePaused?.[entry.source]) continue;