podsync
podsync copied to clipboard
what about migrate to yt-dlp?
Several weeks ago i stoped to get updates from podsync because youtube-dl (2021.06.06) can download video only on very slow speed (about 50kb/s). It was repeateble on several pc's in another locations.
While i do little research i try migrate my instance to https://github.com/yt-dlp/yt-dlp and it was work perfect. Also that have many additional features.
@mxpv what do you think about migrate from youtube-dl to yt-dlp?
FROM alpine:3.10
WORKDIR /app/
RUN wget -O /usr/bin/youtube-dl https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp && \
chmod +x /usr/bin/youtube-dl && \
apk --no-cache add ca-certificates python3 py3-pip ffmpeg tzdata
COPY podsync /app/podsync
ENTRYPOINT ["/app/podsync"]
CMD ["--no-banner"]
Does that new binary just drop in to a new container, or does the code need to change as well? (of which when I tried playing with the code got a bit stuck not knowing golang #238 )
I've noticed really slow downloads as well.
So I've worked out a new dockerfile that preforms a build of go first (I don't have the language). And have successfully built with your referred to yt-dlp. - holy hell it's so much faster.
I'd also started adding for my own interest telling Plex to update but that code failed. But I backed that out and just left the changes to the downloaded.
Hi, for an existing podsync instance that stopped working, do I understand properly from OP that you just install yt-dlp into the existing youtube-dl directory (the wget -O /usr/bin/youtube-dl https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp command) and... that's basically it?
(I'm running podsync through CLI on Raspbian)
@derdide On standalone installation I have successfully tested creating softlink called youtube-dl aimed at yt-dlp. Podsync does not care and the download went through without a problem.
@sutr90 sorry for the late reply, it took me a while to figure out what I was doing wrong - on Raspbian, youtube-dl is located in /usr/local/bin/ - so your wget above was working but was useless... I got it right now and yes, the DL speed is far better.
Several weeks ago i stoped to get updates from podsync because youtube-dl (2021.06.06) can download video only on very slow speed (about 50kb/s). It was repeateble on several pc's in another locations.
While i do little research i try migrate my instance to https://github.com/yt-dlp/yt-dlp and it was work perfect. Also that have many additional features.
@mxpv what do you think about migrate from youtube-dl to yt-dlp?
FROM alpine:3.10 WORKDIR /app/ RUN wget -O /usr/bin/youtube-dl https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp && \ chmod +x /usr/bin/youtube-dl && \ apk --no-cache add ca-certificates python3 py3-pip ffmpeg tzdata COPY podsync /app/podsync ENTRYPOINT ["/app/podsync"] CMD ["--no-banner"]
Can you give me a hint to make this work on the docker container?
@murmelbahn just replace Dockerfile and build image.
@murmelbahn just replace Dockerfile and build image.
Sorry for the maybe dump question but how do I do this? I cloned the repo and replacec the content of the Dockerfile with your Dockerfile. When I run docker build . I get the following error message:
Step 4/6 : COPY podsync /app/podsync COPY failed: file not found in build context or excluded by .dockerignore: stat podsync: file does not exist
I dont know how to pass this error:(
You need the binary for podsync. Go compiles it. The dockerfile as written needs a compiled binary to make the container.
Aaah, thank you. That was the missing piece;) Now its working.
Hi @mxpv , is this still planned? Youtube-DL performs very badly compared to YT-DLP on slow internet connections, and it's quite complicated to compile an image manually according to Comment #1.
Cheers
Yeah having this supported by default would be excellent! Also being able to configure the default timeout value of yt-dlp to something other than 10 mins would be excellent :+1: Thanks :)
Yes, will I'll take a look, but PRs are welcome :)
Yes, will I'll take a look, but PRs are welcome :)
I'm not too experienced with the code here, but isn't the only thing that needs changing the Dockerfile? Does the rest of the code depend on YT-DL specifically? YT-DLP should be fully pin-compatible otherwise.
Yeah tbh after doing some experimentation, I realised it is very easy to fix this problem on my end. I simply installed yt dlp to the same location as I would usually install the YouTube-dl binary, so it is activated by calls to YouTube-dl.
I also figured out that compiling podsync code is as simple as typing "make" into the terminal of the project folder (this should probs be stated in the readme.md file :), so I was able to adjust the time out value from 10 mins to 35 mins which has significantly improved my download success rate.
Yes, will I'll take a look, but PRs are welcome :)
Can do a PR. Easiest would be to just update the Dockerfile to download the yt-dlp binary, but name it youtube-dl to prevent regressions. This could also be done with a different docker image tag. e.g. mxpv/podsync:yt-dlp (=latest) and mxpv/podsync:yt-dlp-2.4.1
Else podsync could embrace yt-dlp and recommend it over youtube-dl with probably a new major version number because it would be a breaking change. This would involve a bigger refactor to yt-dlp.
FYI, the PR to start using yt-dlp has just been merged, so podsync will start using it starting the next release.
Several weeks ago i stoped to get updates from podsync because youtube-dl (2021.06.06) can download video only on very slow speed (about 50kb/s). It was repeateble on several pc's in another locations.
While i do little research i try migrate my instance to https://github.com/yt-dlp/yt-dlp and it was work perfect. Also that have many additional features.
@mxpv what do you think about migrate from youtube-dl to yt-dlp?
FROM alpine:3.10 WORKDIR /app/ RUN wget -O /usr/bin/youtube-dl https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp && \ chmod +x /usr/bin/youtube-dl && \ apk --no-cache add ca-certificates python3 py3-pip ffmpeg tzdata COPY podsync /app/podsync ENTRYPOINT ["/app/podsync"] CMD ["--no-banner"]
hey! I'm also having trouble with youtube-dl and I would like to try yt-dlp but I barely know what I'm doing here. Could you provide me with more details on how to do what you did? would be great. thanks
@skofieldO5 I’m not sure on the ETA of the next release, but if you wait until then YT-DLP will be built in.
@LewisSpring oh cool! Well I really don't care if it is youtube-dl or yt-dlp. I tried installing all kind of versions of youtube-dl and got different error message. Right now my log looks like this:
"^[[36mINFO^[[0m[2022-07-15T17:48:55Z] ! downloading episode https://youtube.com/watch?v=0MIkxQDTuqA ^[[36mepisode_id^[[0m=0MIkxQDTuqA ^[[36mindex^[[0m=4
^[[31mERRO^[[0m[2022-07-15T17:48:56Z] youtube-dl error: /tmp/podsync-901732990/0MIkxQDTuqA.%(ext)s ^[[31merror^[[0m="failed to execute youtube-dl: exit status 1"
^[[31mERRO^[[0m[2022-07-15T17:48:56Z] [youtube] 0MIkxQDTuqA: Downloading webpage
ERROR: 0MIkxQDTuqA: YouTube said: Unable to extract video data"
Any help with that would be great. I would like to surprise them that I turned their channel into a podcast ;)
@skofieldO5 Do you run it in docker or another way? If in docker, you need an image with yt-dlp included (e.g. the one from Th0masL (th0masl/podsync:ytdlp) or hack it into the image (I use a custom entrypoint script to handle the modification)
Either way, podsync does only supports binaries called youtube-dl. So you need to rename or add a symlink if you use a fork/variant
@pagdot thanks! I made it work with a symlink.
I see this issue hasn't had any activity for over a year, does the current release use yt-dlp? The documentation still says youtube-dl. I see there is a fork of it by another developer which does use yt-dlp, but it hasn't been updated since December and I would rather stick to the official repo. I can just run without Docker but I'd prefer not to.
Current version uses yt-dlp https://github.com/mxpv/podsync/blob/5c57096643ccb7666b1f2a4b94f559bb706369a9/Dockerfile#L13