Jeeaaasus / youtube-dl

Automated yt-dlp Docker image
https://hub.docker.com/r/jeeaaasustest/youtube-dl/
MIT License
258 stars 33 forks source link

Question: Sponsorblock-Remove Option #52

Closed wjbridge closed 2 years ago

wjbridge commented 2 years ago

Hey Jeeaaasus,

Great job on this docker container! I know you stated that this option was not supported due to a bug with ffmpeg --sponsorblock-remove, currently unsupported because of a bug with ffmpeg. I was wondering if you tried to use a patched version from FFmpeg-With-VP9-Timestamp-Fix. I found this potential solution here.

I was trying to redirect yt-dlp to use this patched ffmpeg version using --ffmpeg-location but getting yt_dlp.postprocessor.ffmpeg.FFmpegPostProcessorError: ffmpeg not found. Please install or provide the path using --ffmpeg-location. I cannot seem to remedy this error.

Wondering if anybody else had a solution or considered this? I was looking to remove all these "sponsors" from these videos.

Jeeaaasus commented 2 years ago

Hello @wjbridge! Yep, I was the one that opened that issue :D

There are some dependencies that are missing, I don't know all of them, if you simply try to run that patched ffmpeg you get an "location not found" response, because some binary is missing. If you do apk add gcompat you instead get an actual error but I couldn't figure out what dependency is missing.

I've experienced quite a lot of annoyances with Alpine and as such I figure it's more worth to just change base image instead of trying to work around these issues. Haven't gotten around to starting that just yet, but I also want to use that feature of yt-dlp.

nihil-admirari commented 2 years ago

Hi, the author of SponsorBlock code is here.

This issue was raised previously: https://github.com/yt-dlp/yt-dlp/pull/360#issuecomment-864551562, conclusion:

But when i tried an ubuntu image sure enough it works, so something with the alpine image was going weird

FFmpeg-Builds seems to work only on glibc-based distros.

Jeeaaasus commented 2 years ago

Hello @nihil-admirari!

I don't know enough to be certain, but yeah, I'm also pretty sure musl-libc is the underlying issue and going away from Alpine will fix it.

Since I already have you here, any pointers on how to easily integrate your latest patched ffmpeg into my image? thanks :)

nihil-admirari commented 2 years ago

Extracting bin/* into /usr/local/bin would be the easiest way (assuming the latter is in the $PATH).

Jeeaaasus commented 2 years ago

@wjbridge --sponsorblock-remove should work correctly in the latest image, let me know if there's any issues. :)

wjbridge commented 2 years ago

@Jeeaaasus I just tested it and it works! Thanks so much!