mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-10-27 07:52:24 +00:00
A WebTorrent-only card's sole liveness signal is the swarm probe (20s timeout, 5min cache), and P2P liveness is slow + intermittent — a live-but-slow video is indistinguishable from a dead one until that probe finishes. Hiding such a card until the swarm verifies could bury perfectly good P2P content for minutes. hide-until-verified now only suppresses a card while the FAST, reliable CDN probe is still running. Once the CDN resolves dead (or is absent, i.e. P2P-only), it falls back to show-pending for the WebTorrent part: shown while the swarm is checked, hidden only once it too is confirmed dead. Burying live content is worse than a brief flash of a dead one, and only the slow P2P probe is at issue. cardNeedsEagerLivenessProbe likewise skips P2P-only cards (they start visible). Tests: hide-foreign does-not-bury-WebTorrent-only coverage in tests/video-card-source-visibility.test.mjs. Co-Authored-By: Claude Opus 4.8 <[email protected]>