feat(web): up avatars, follower count, and dedupe views/avg secondary

This commit is contained in:
kairee committed 2026-11-01 14:34:23 +08:00
1 parent 1ed3746f4b
commit 2ff3e7952b
23 files changed
+209 -58

No files matched your search

+2 -1
View File
@@ -45,7 +45,7 @@ def detail(
data["pubdate"] = pubdate
data["ctime"] = pubdate
data["duration"] = duration
data["owner"] = {"mid": up_mid, "name": up_name, "face": ""}
data["owner"] = {"mid": up_mid, "name": up_name, "face": "http://i1.hdslb.com/bfs/face/u.jpg"}
data["pages"] = [{"cid": 1, "page": i + 1} for i in range(pages)]
return VideoDetail.from_api(data)
@@ -150,6 +150,7 @@ def test_ingest_candidate_added_and_snapshot():
assert video["source"] == "candidate:telegram"
assert video["folder_id"] is None
assert video["up_mid"] == 100
assert video["up_face"] == "http://i1.hdslb.com/bfs/face/u.jpg"
snap = repo.get_snapshot(DATE, 9)
assert snap is not None and snap["ok"] == 1 and snap["view"] == 819
assert ups.calls == [([100], {100: "UP100"})]