ikuyo

the Curly Brace scholar

33, married, trans. Developer by day, TASer in the night, musician somewhere in between. Married to @amberciera.


ikuyo
@ikuyo

Here's a lil Python 3 script I made that takes an URL from an album uploaded at KHInsider.com and downloads all the music for you without needing to make an account!

Python 3.6 and up required, as well as a couple dependencies. I'd appreciate some help to make it a bit better, feel free to send a PR! I wanna add a way to output the content to an specified directory rather than to the main one, add a progress bar if possible, or general speed optimizations (I'm not that experienced with async python).


You must log in to comment.

in reply to @ikuyo's post:

I've got some code I use for downloading multiple things at once using aiohttp (for my pkmncards dot com project) but the code is even messier than yours. It does help parallelize a bunch of small downloads really well, though. It doesn't have a progress bar, but you could theoretically hack one in, but it'd be based on the number of files and not bytes. Not sure how you'd do better without complicating the loop a lot (to pre-poll all the URLs with HEAD to get byte sizes before starting the actual downloads. if the files aren't very big it may not be worth the time delay / code complexity.)