Closed JeFi2 closed 3 years ago
Since the sponskrub fork recommended for use with the popular yt-dlp project has all the of optional categories enabled by default, it's now completely broken as well.
This issue broke my WIP automated yt-dlp docker container, thankfully I found this issue before ripping my entire docker network stack apart.
So after adding a bunch of writefln() print statements around core areas where the application interacts with the API, the issue seems to stem from whitespace in the categories list of the API request.
Right now the application generates urls such as http://sponsor.ajay.app/api/skipSegments?videoID=y8XvQNt26KI&categories=["sponsor", "intro"]
which seems to cause a URL using bad/illegal format or missing URL
error in std.net.curl
. I'm not familiar with dlang but I guess it's an issue stemming from a lack of URL-encoding of strings before making the API requests.
After removing the spaces following the commas in each .join(", "
) within the following lines, things seem to be working again. https://github.com/faissaloo/SponSkrub/blob/3077602bff10463e5e87af2c8eb95ed285d21336/src/sponskrub/sponsorblock.d#L54
&
https://github.com/faissaloo/SponSkrub/blob/3077602bff10463e5e87af2c8eb95ed285d21336/src/sponskrub/sponsorblock.d#L64
Should be fixed in master, I'll try and do a release later today. Let me know if there are any further issues.
Optional categories don't work anymore:
Maybe this is because they added an additional "preview" category some time ago.