fix(download): 连续 3 轮查不到才判移除(M1)

qB 列表与按 hash 都查不到时先记 missing_since / missing_count,连续 MISSING_CONFIRM_ROUNDS(3) 轮才判 removed;中途重新出现或只是去掉管理标签即清零。相关测试改为同步多轮后再断言移除。

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Cxwgnn2pbzQ7rXv3rq7fei
This commit is contained in:
rootandClaude Opus 5.5 committed 2026-10-03 21:20:08 +08:00
1 parent cba5de731b
commit d96f0ff19f
4 files changed
+25 -6

No files matched your search

@@ -41,6 +41,8 @@ describe.skipIf(!hasPg)("E15 Agent 质量(fake 模型 + 真实能力)", () => {
name: "Dune.Part.Two.2024.1080p.BluRay.x264-GRP",
status: "failed",
last_error: JSON.stringify({ message: "qB 状态 missingFiles" }),
// 已连续缺席两轮:下一轮同步即确认移除(多轮缺席才判移除)
missing_count: 2,
})
.returning("id")
.executeTakeFirstOrThrow()