Images and tracks named by a prefix alone are bounded by the counter's total
Test and deploy / test (push) Successful in 1m3s
Test and deploy / edge (push) Successful in 2m10s
Test and deploy / deploy (push) Successful in 3m17s

"[…/559] - "lop1001.jpg"", "pic004.jpg", "DSC_0002[1].jpg", and tracks
"r86_022 - Gwen Guthrie - ….mp3" ("r"): the stem route keyed them by the
letters before the number alone, so every post of a poster was one release
(5,731 images for 559; 6,433 tracks for 457). Under a counter its total is
part of the key; a cover named as its archive's stem keeps the stem's key.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Daan MeijerandClaude Opus 5.5 committed 2026-10-13 23:54:02 +02:00
1 parent 3f6bb8b162
commit 9f255e6ac0
3 files changed
+43 -4

No files matched your search

+10
View File
@@ -433,6 +433,16 @@ test.group('release / par2 names', () => {
assert.equal(alexi('01', '57295b').key, alexi('02', '32202b').key)
})
test('a set named by its prefix alone is bounded by its counter', ({ assert }) => {
const id = (subject: string, name: string) => releaseIdentity({ poster: 'p', subject, name, weak: false })!
const lop = (i: string, total: string, n: string) => id(`[${i}/${total}] - "${n}" yEnc`, n)
assert.equal(lop('001', '559', 'lop1001.jpg').key, lop('002', '559', 'lop1002.jpg').key)
assert.notEqual(lop('001', '559', 'lop1001.jpg').key, lop('001', '1018', 'lop5001.jpg').key)
const r = (i: string, total: string, n: string) => id(`[${i}/${total}] - "${n}" yEnc`, n)
assert.equal(r('022', '457', "r86_022 - Gwen Guthrie - Ain't Nothing Going on but the Rent.mp3").key, r('085', '457', "r88_085 - Gregory Abbott - I'll Prove It to You.mp3").key)
assert.notEqual(r('022', '457', "r86_022 - Gwen Guthrie - Ain't Nothing Going on but the Rent.mp3").key, r('022', '333', "r98_333 - Jellie - Roller Coaster.mp3").key)
})
test('an image without words around it is keyed by its set', ({ assert }) => {
const id = (name: string, counter: string) => releaseIdentity({ poster: 'p', subject: `##[ "${name}" (${counter})`, name, weak: false })!
assert.equal(id('diana-040-001.jpg', '01/68').key, id('diana-040-002.jpg', '02/68').key)