Rebuild: completeness as indexed, file totals from any counter, pausable tails, progress by articles
- releases.complete is computed with every batch (files >= the counter's total) instead of only when a release settles after 6 quiet hours: the 'complete' filter matched nothing in a fresh catalog. - A release's file total comes from any counter form (counterTotal: '(01/10)', 'File 27 of 132', …), not only [i/M]; the post rule's key keeps the [i/M] total, so keys are unchanged. Both implementations. - groups.tail: a group's live tail can be paused (its history and owner priority stay), e.g. to let other groups' history go first. - Stats: history by articles, and the current pass (history ranges before those deferred 2000 priorities behind) as its own figure; the header showed 0.1% of ranges counting 145k deferred ones. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
7b7175c229
commit
d0f3497ec9
8 files changed
+57
-17
No files matched your search
@@ -57,9 +57,13 @@ test.group('Releases API', (group) => {
|
||||
const detail = (await client.get(`/api/v1/releases/${tv.releases[0].id}`)).body() as { files: { name: string; parts: number; size: number }[] }
|
||||
assert.deepEqual(detail.files, [{ ...detail.files[0], name: 'Some.Show.S01E01.1080p.WEB.mkv', parts: 2, size: 1400001 }])
|
||||
;(await client.get('/api/v1/releases/999999')).assertStatus(404)
|
||||
const stats = (await client.get('/api/v1/stats')).body() as { releases: number; ranges: { total: number } }
|
||||
// Complete as soon as the counter's files are all found (settling makes it final).
|
||||
const complete = (await client.get('/api/v1/releases?complete=1')).body() as { releases: unknown[] }
|
||||
assert.lengthOf(complete.releases, 2)
|
||||
const stats = (await client.get('/api/v1/stats')).body() as { releases: number; ranges: { total: number }; history: { total: number } }
|
||||
assert.equal(stats.releases, 2)
|
||||
assert.equal(stats.ranges.total, 1)
|
||||
assert.equal(stats.history.total, 1000)
|
||||
|
||||
// Newznab: caps, a TV search with season and episode, the NZB; the key when one is set.
|
||||
const caps = await client.get('/api?t=caps')
|
||||
|
||||
Reference in new issue
Block a user