Fall through to the post page when a reel embeds only its cover frame #21

Merged
thatguygriff merged 1 commits from fix/instagram-reel-video into main 2026-09-17 00:00:12 +00:00
Member

What

Instagram reels were resolving to a still image instead of a video.

Why

The captioned embed stopped shipping a reel's video_url, and its logged-out player never draws a <video> element — so both the payload path (shortcode_media had is_video: true but no video_url) and the DOM path returned only the cover frame. Because that poster still counted as media, scraped.media.length was truthy and the existing post-page fallback never fired.

Fix

Trigger the post-page fallback when the URL is a reel (or the payload declared a video) but no video was resolved. The post page's payload still carries the progressive MP4 in video_versions (the shared meta-media schema). The embed's caption, handle and avatar are carried forward, since the post-page payload does not include the owner.

Verification

  • npm run resolve now returns a video with the cover frame as poster, correct handle, avatar, caption and dimensions.
  • New fixture test/fixtures/instagram/reel-video-versions.json (real post-page payload) plus a test in test/instagram.test.ts asserting a reel resolves to a progressive video with its cover frame as poster.
  • npm run typecheck and npm test (159 pass) both green.
## What Instagram reels were resolving to a still image instead of a video. ## Why The captioned embed stopped shipping a reel's `video_url`, and its logged-out player never draws a `<video>` element — so both the payload path (`shortcode_media` had `is_video: true` but no `video_url`) and the DOM path returned only the cover frame. Because that poster still counted as media, `scraped.media.length` was truthy and the existing post-page fallback never fired. ## Fix Trigger the post-page fallback when the URL is a reel (or the payload declared a video) but no video was resolved. The post page's payload still carries the progressive MP4 in `video_versions` (the shared meta-media schema). The embed's caption, handle and avatar are carried forward, since the post-page payload does not include the owner. ## Verification - `npm run resolve` now returns a `video` with the cover frame as poster, correct handle, avatar, caption and dimensions. - New fixture `test/fixtures/instagram/reel-video-versions.json` (real post-page payload) plus a test in `test/instagram.test.ts` asserting a reel resolves to a progressive video with its cover frame as poster. - `npm run typecheck` and `npm test` (159 pass) both green.
Kydoimos added 1 commit 2026-09-16 23:57:41 +00:00
Fall through to the post page when a reel embeds only its cover frame
CI / Typecheck, test, build (pull_request) Successful in 29s
cc4f094fb8
The captioned embed stopped shipping a reel's video_url and never draws a
logged-out <video>, so both the payload and the DOM hand back the cover
frame alone. Because that still counts as media, the post-page fallback
never fired and a reel resolved to a still image.

Trigger the fallback when the URL is a reel (or the payload declared a
video) but no video was found, so it reaches the post page, whose payload
still carries the progressive file in video_versions. The embed's
caption, handle and avatar are carried forward, since the post-page
payload does not include the owner.

Co-authored-by: anthropic/claude-opus-4-8
Kydoimos force-pushed fix/instagram-reel-video from f968ac749c to cc4f094fb8 2026-09-16 23:57:41 +00:00 Compare
thatguygriff merged commit 1f1f777374 into main 2026-09-17 00:00:12 +00:00
thatguygriff deleted branch fix/instagram-reel-video 2026-09-17 00:00:13 +00:00
Sign in to join this conversation.
No Reviewers
No labels
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Unsupervised/antisocial#21