The damn vid is not available anywhere else.

Extra bonus annoyance - it’s only available if you’re in/near Seattle. Or if you use a VPN like I did. I don’t know much but I tried everything I could think of and I got nowhere. For example - I tried to download the source src.

War; #108; The Knife Edge of Deterrence - American Archive of Public Broadcasting

<video class="vjs-tech" id="player_media_html5_api" aria-label="video player" oncontextmenu="return false;" preload="metadata" crossorigin="with-credentials" data-setup="{}" poster="https://s3.amazonaws.com/americanarchive.org/thumbnail/cpb-aacip-283-95j9kqg6.jpg" flashstopped="true" tabindex="-1" src="blob:https://americanarchive.org/ef78ba32-3b0a-4548-a3d1-2f925b5123bd"> <source src="/media/cpb-aacip-283-95j9kqg6?part=1" type="application/x-mpegURL"> </video>

Rant. Fucking PBS.

  • AernaLingus [any]@hexbear.net
    link
    fedilink
    English
    arrow-up
    13
    ·
    edit-2
    1 month ago

    So, I first tried just chucking the URL at yt-dlp–no luck, since there isn’t an extractor for that site/embed.

    Not to worry, though! All you need to do is open up your dev tools (Ctrl+Shift+I or F12), click the Network tab, type m3u8 into the filter box, and refresh. You should get a few requests popping up there–if not, start the video. Grab the URL for the one that starts io.cimediacloud.com by right-clicking and copying the URL.

    Then, at the command line, you can simply run

    yt-dlp "[your long URL but without these square brackets]"
    

    and it should seamlessly download and decrypt the transport stream and then remux into a proper MP4 file!

    If you want to get a little fancier, you can use streamlink to download it–if you use the --stream-segments 10 argument it’ll download nigh-instantaneously if you have a fast connection (compared to yt-dlp which took about a minute for me), but you’ll then need to remux it manually with ffmpeg:

    streamlink --stream-segment-threads 10 "URL" best -o video.ts && ffmpeg -i video.ts -c copy -movflags +faststart video.mp4.
    

    I elided some details because I’m on my phone, but hopefully my explanation was clear enough to follow (and search anything up that wasn’t covered explicitly). If you have any questions, I’ll answer them tomorrow when I get the chance. Also, I’d be happy to just upload the video for you as well if you’d prefer.

    edit: typo

    • InevitableSwing [none/use name]@hexbear.netOP
      link
      fedilink
      English
      arrow-up
      5
      ·
      edit-2
      1 month ago

      Thanks.

      Network tab

      I know how to use yt-dlp

      But I always get stuck in the damn network tab. I have no idea what I’m doing. Where are the vid streams hiding? Network > sources >page? So close yet so far away.

      • loathsome dongeater@lemmygrad.ml
        link
        fedilink
        English
        arrow-up
        5
        ·
        1 month ago

        Your network section is obscured. I don’t use chrome but I suppose it is the very thin white area above “sources” and below where you typed m3u8. Try dragging its edge to make it bigger.

      • AernaLingus [any]@hexbear.net
        link
        fedilink
        English
        arrow-up
        2
        ·
        1 month ago

        As others have said, you’ve got the console drawer (with the tabs “Console,” “Elements,” “Sources”, “Issues”) obscuring all the content in the main panel, with only that tiny sliver poking through. You can either close it entirely with the x all the way to the right (which is what I do) or resize it by dragging. To re-add any tabs from the console drawer to the main panel, click the ⋮ in the upper right-hand corner of the panel, then “More tools” to show all the tabs you can add.

  • starlight32 [any]@hexbear.net
    link
    fedilink
    English
    arrow-up
    12
    ·
    1 month ago
    • open javascript console

    • get the value of videojs.players.player_media.tech().vhs.playlists.src (hls playlist link from the video player)

    • run ffmpeg -i [hls playlist link] -c copy [filename].mp4

    this worked for me

    • InevitableSwing [none/use name]@hexbear.netOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      edit-2
      1 month ago

      Thanks. I procrastinated so I grabbed that. I’ll download Firefox onto this stupid computer and I that will solve my inability to find the damn streams in the network tab + solve other issues too.