A random poster per file is no part of a release key
Test and deploy / test (push) Successful in 44s
Test and deploy / edge (push) Successful in 1m47s
Test and deploy / deploy (push) Successful in 1m45s

Releases 78361820 and 78411563 were two files of one FTD upload
("Yusef_Lateef-Alight_Upon_the_Lake_…-WEB-2026-FTD", [1/6] and [3/6], 4 s
apart) under a new random poster each ("N9vplIaavBCz@aCTVoAsk.JSE",
"FVWWHku0fGAg@QfaTz0g0.RVH"): the stem key includes the poster. When the
poster's own name (before the @) looks random, it's left out of the key;
real posters keep theirs (two uploaders of one scene release at the same
time stay apart), and uploads hours apart stay apart by the re-upload
rule. Both implementations; tests; fixtures identical.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Daan MeijerandClaude Opus 5.5 committed 2026-10-11 21:55:15 +02:00
1 parent b1213fbea0
commit df35f4678c
3 files changed
+55 -5

No files matched your search

+12
View File
@@ -175,6 +175,18 @@ test.group('release / par2 names', () => {
assert.equal(par2ReleaseName(['Album.Name-2024-GRP.part01.rar', 'Album.Name-2024-GRP.part02.rar']), 'Album.Name-2024-GRP')
assert.equal(par2ReleaseName(['only.one.file.2024.mkv']), 'only.one.file.2024')
})
test('a random poster per file is no part of the key; a real poster is', async ({ assert }) => {
const { randomPoster } = await import('#lib/release/identity')
const ftd = '-Alight_Upon_the_Lake_(Live_at_the_Jazz_Showcase_Jun_1975)-WEB-2026-FTD'
const a = releaseIdentity({ poster: 'N9vplIaavBCz@aCTVoAsk.JSE', subject: `[1/6] - "Yusef_Lateef${ftd}.par2" yEnc 1744`, name: `Yusef_Lateef${ftd}.par2`, weak: false })!
const b = releaseIdentity({ poster: 'FVWWHku0fGAg@QfaTz0g0.RVH', subject: `[3/6] - "Yusef_Lateef${ftd}.part2.rar" yEnc 104857600`, name: `Yusef_Lateef${ftd}.part2.rar`, weak: false })!
assert.equal(a.key, b.key)
assert.isTrue(randomPoster('N9vplIaavBCz@aCTVoAsk.JSE'))
assert.isFalse(randomPoster('Captain Salvo <Capt@Salvo.com>'))
assert.isFalse(randomPoster('Poster49118 <Poster49118@generic.mail>'))
assert.isFalse(randomPoster('w.merklein@freenet.de (muffin)'))
})
test('image sets: sizes in brackets and one-word set names', ({ assert }) => {
const id = (subject: string, name: string) => releaseIdentity({ poster: 'p', subject, name, weak: false })!
assert.equal(id('Aletta Ocean - "100628-035.jpg" yEnc [347K]', '100628-035.jpg').key, id('Aletta Ocean - "100628-036.jpg" yEnc [298K]', '100628-036.jpg').key)