fe80Grau / ytdlp2STRM

A little script to serve Youtube / Twitch / Crunchyroll videos without storage it. Uses yt-dlp HTTP data throught Flask and dynamic URLs. We can use this dynamic URLs to set STRM files.
https://github.com/fe80Grau/ytdlp2STRM
MIT License
228 stars 21 forks source link

Keep live videos even if ytdlp2strm_keep_old_strm is False #73

Open Druidblack opened 2 months ago

Druidblack commented 2 months ago

Безымянный 6566

The ytdlp2strm_keep_old_storm option does not delete old files.

Should old files be deleted every time cron is started?

fe80Grau commented 2 months ago

Fixed with the last commit, generatin docker cointarner in few minutes

Druidblack commented 2 months ago

I am using the latest version of the docker file. When you restart, new files are created for the video, the old ones are not deleted.

Druidblack commented 2 months ago

345345

fe80Grau commented 2 months ago

Please wait, the latest Docker container doesn't have the latest commit. I'm uploading the file right now and it takes 10 minutes to generate the different containers for each architecture. Please be patient... to check for quick changes, you can run ytdlp2strm directly on your host.

With the latest update you will have the solution for the descriptions and the deletion of old files. Remember that this option will delete all the strm files previously generated for the current execution, this way you always have a fresh list of only the last N days configured in each plugin.

As I said, as soon as the Docker image is uploaded I will let you know. In the meantime, please be patient and avoid posting multiple times, you can always edit your message, there is no need to generate so many messages as it can be somewhat stressful for everyone.

fe80Grau commented 2 months ago

Check last docker image and tell me

Druidblack commented 2 months ago

Everything is working now. Old files are deleted. Idea. Is it possible to check when the first strm file was created and is the broadcast still ongoing? If the broadcast was not interrupted after the first creation of storm, then the file does not need to be recreated.

fe80Grau commented 2 months ago

I'm glad it works, about the new feature.

EDIT: Are you working with /streams right? You want is that if strm is "live"/"on air" at the same time ytdlp2strm wants to delete it, it won't be deleted?

EDIT 2: I see that the channel you show in the screenshot has been live for months. I will see what I can do for you and implement this feature.

Druidblack commented 2 months ago

Yes, you understood my request correctly.