Hacker News new | ask | show | jobs
by nzmsv 2053 days ago
Back when Udacity just launched with their first course (Thrun's self driving car intro) I wanted to watch the videos on a big screen. I had a somewhat smart TV that could play files off a USB stick but did not have Internet access. Udacity hosted all their videos on YouTube at the time and there was no convenient way to download them. So I spent an afternoon hacking together a Chrome extension that would modify the Udacity website DOM and give me download links for the lectures (it had to be an extension to get around same origin restrictions). Udacity had some weird naming convention for their videos so I had to make some calls to their API as well as YouTube and correlate videos with titles. The YouTube part was "influenced" by youtube-dl. This was much faster than reverse engineering, even though I was writing new JavaScript and not using the original Python. Anyway, trivial stuff.

After watching the videos from my couch for a few days I decided to post a link to my extension on the Udacity message board... and it absolutely blew up! My dinky little extension had thousands of users all over the world seemingly overnight.

But the absolute highlight was getting an email from a student from Iran. Iran just blocked YouTube because of https://en.wikipedia.org/wiki/Innocence_of_Muslims and there was a whole group of students who could no longer participate in the course. Apparently they had some friends at a US university use my extension to download the videos and reupload to a VPS they ran. I was blown away - my quest to sit on a couch ended up accidentally helping fight censorship.

I maintained the extension until Udacity added a native video download feature and then took it down. But it was an interesting experience and definitely shaped my perception of fair use laws. They are important. People have way more legitimate uses for information than lawyers can imagine.

1 comments

> my quest to sit on a couch ended up accidentally helping fight censorship

That's brilliant! We can never predict the impact our tools will have on people's lives.

Your idea of partially porting youtube-dl to the browser gives me an idea... would it be feasible to port it fully? I think the biggest hurdle would be ffmpeg, but a few days ago I saw "A pure WebAssembly / JavaScript port of FFmpeg": https://news.ycombinator.com/item?id=24987861

With webassembly right now I'm doing wild things right now, I'm sure it is possible and will happen. We already have ytdl-core js [1]

[1] https://www.npmjs.com/package/ytdl-core