au PAY videos should be recorded in the database #5
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Initial Proposal
Database
segment
table for au PAY Market shows.schedule
table normally.schedule.video_id
field could contain the numeric id that they use, and a variety of URLs can be generated based on that.Template
schedule.video_id
is a YouTube video_id.Strangely, the page for id 10211 doesn't show a video.
https://wowma.jp/event/live-tv/play.html?live_id=10211
I can confirm that the m3u8 link shows Ayaka though.
https://vod.check.tv/lives/10211/360p/index.m3u8
Once that link generation is fixed, maybe you could have links to open the m3u8 streams in a video player in browser to make it easy for non mpv-users to watch.
Thumbnails are easy to derive.
>>>/jp/44501949
https://image.check.tv/lives/10213/vertical.jpg
https://image.check.tv/lives/10211/vertical.jpg
Do you have any JavaScript video player recommendations? I don't know what's good these days. Oh wait. I can just use the
<video>
tag. Never-fucking-mind.lul I was going to suggest looking at the video players aqstream and another free foreign tv site uses. I remember one of them is GPL'd, but I don't remember whether it provides features over the
<video>
tag.I put one au PAY entry into the schedule to see how it looks.
Depending on browser and platform, the
<video>
tag may not be able to handle streams on its own. It seems phones are often more capable by default there. However, there are libraries that can fill in the gaps.https://github.com/videojs/http-streaming
https://github.com/videojs/video.js
@pta - The links are busted, but I got everything I could in the database using the new
bin/aupay-insert.pl
script. I forgot that I was trying to learn Julia and ended up doing it in Perl.https://gg.vern.cc/wn/segment/?n=au+PAY
The Mystery of
10211
#あやちとプレイバック
.2023-07-27T18:00:00+09:00
.I was wondering where Julia was going to be used for the website. The Haskell library I was trying out the other day throws type errors in ghci if you try to generate invalid html, like putting a
<p>
in the<head>
. The parser Julia libraries you linked look good.The m3u8 and thumbnail links work. I guess you'll eventually make the "vid" links open a reliable in-browser player.
Since Nana didn't do any pre-stream youtube streams, I'm eager to find those manually. But first, I need to write a little shell function wrapper for graphicsmagick to combine kindle book page fragments into full-page images so I can easily post gravure from Yui and other casters' photobooks.
The ranking page should note the day you started counting appearances.
I can't get Julia to run at all on vern.cc -- not even a REPL. The nix packaged version refuses to install, because the package is broken. Also the packaged version is really old. I then tried downloading the latest binaries, and they won't run either. It's weird.
I think I'm just going to keep the web site as little Perl CGI scripts.
They love correctness.
Maybe the next time I need to scrape, I'll try them. I didn't even think to look for Julia libraries until I was mostly done with the Perl-based scraping solution.
When I wrote that initial comment, they were still broken YouTube-based links. I was thinking of calling it a night, but I couldn't leave those links totally broken. I still want to swap out the templating system, so I don't want to mess with the existing templates too much more.
It should be a fun little project. I think you've mentioned this a few threads ago.
Eventually, I'd like to have monthly and yearly breakdowns, but right now, it's scanning the whole schedule table.
Cockblocked by CORS?
My first attempt at trying to use video.js yielded this error message.
What's funny is that if I use a plain old
<video>
tag without video.js, it works on my phone but not on the desktop. The video tag on the phone is more capable somehow.This turns out to be harder than I thought. I just looked at some old stackoverflow threads about playing m3u8 with the video tag and they all conclude that just a few browsers support it. The video tag was only really meant to play mp4, webm, ogg, etc. Not HLS or whatever.
The first answer to this stackoverflow thread talks about the CORS thing. I don't quite get it, but I seems like work that vern would have to do on the webserver. You might just have to stick to the phone-capable links. Desktop users should be using mpv or vlc anyways.
I'm going to consider this issue closed for now.
That was fun.