section83/MacYTDL

[Feature Req'] Timestaps in the logs

zxzzz8 opened this issue · 9 comments

when i download a batch, it sometimes can take more then a day, in which case i many times have disconnects,
while these disconnects break the files, once they do, in the log file of the batch,
there is no indication when that happened, nor when the internet went back up and it started the next file....
this results in a situation were i have no idea when anything happened,
as the ''how long the download took'' depends on knowing when it started, which after a disconnect, its completely unknown.

knowing when things happened might be almost the most important job of a log for me,
this is why this bugged me for quite a while, and i find it as the most important feature request i currently have that is not implemented yet....
tbh id obviously prefer that every line in the log will have a timestamp, so id be able to easily see if suddenly my unstable internet speed slowed down the download speed, which happens a lot.... and when, if at all, it speeded back up,
with constant timestamps, i can see at what time it completed what % from the file.... enabling me to know the speed and everything that happened....

what i mean is, the estimate and speed it gives doesn't feel much useful w/o knowing WHEN it happened....

I have little control over what YT/YT-DLP output. I can't force them to timestamp events. It's even more difficult if YT/YT-DLP offload downloading to FFmpeg. We could add the suggestion to YT-DLP (YT is no longer being maintained).

yes please, if you could put a feature request there, as i don't exactly know what to ask them so that your app will be able to have this in the log files....

I've lodged a suggestion for YT-DLP: yt-dlp/yt-dlp#1866.

It might take a while to get an answer which might be a negative but, worth a try.

Cheers.

Hey zxzzz8,

This is my first attempt to get a timestamp. Will this do ?

youtube-dl_response-youtube-dl_test_video_''_ä↭𝕐.-Friday_3_December_2021_at_2_13_59_pm.txt

I should be able to play with the format.

i always do the date something like [2021-12-03] in numbers, because like that it follow the same behavior of the hour:min:sec and from biggest variable to the smallest etc'.... so that will be really the best for me if you can do that, and i think its most clear and universal as well.... ^^

btw another thing, i had cases where i had to download a vid using the batch-tool only, and couldn't using the normal way, coz it gave an error that the log file name is too long.... so i think there is also technical issues using the long 'Friday' and 'December' in the name of the log file as well,
not to mention that in ''order by name'', it doesn't set nicely at all X /

I can't get timestamps to work properly at this time. So, I'll put off that change to 1.20. In the meantime, I need to fix the urgent bugs for version 1.19.2.

i had cases where i had to download a vid using the batch-tool only, and couldn't using the normal way, coz it gave an error that the log file name is too long

Very odd. MacYTDL has handled log file names with 168 characters. It doesn't have a warning for the length of file name so, I suspect something else was going on. Can you find the URL so I can test it ?

Thanks.

well you also need the long naming template i have, tho i shortened it quite a bit so to try to avoid this issue,
but i think it still does it occasionally? but you can just add some text to it to see the issue :
%(id)s = 1%(upload_date)s-Date = %(uploader)s = %(timestamp)s-UNIXtime =-= %(fulltitle)s =-= %(format)s .%(ext)s

as for a link, twitch delete stuff after a while, but i think this fresh link might have the max naming length, so it should do for this testing i think?
https://www.twitch.tv/videos/1204403822

i do very much like that the log file have the name of the file in it, but then it needs to be efficient with the stuff the user can't manage, like the date not having long names like 'Friday' and 'December' ....

alternatively, or actually regardless, it can also just have the first part of the name of the file in the log-name instead of the whole file name in the log-name, meaning cutting whatever else it can't include in the log name, its ok to cut it if its just the log i think....
and btw i always try put the most identifying information on the vid at the start of its name, so that will work with it really well for me,
just don't cut the actual video name on the vid file, thats important to stop me and give me an error, or in batch just skip it and leave why skipped inside the log, etc, as it does now.... XD

oh i wasn't clear i guess, i don't think it gave me an error explaining the issue, it gave me some odd error i think? and i realized after try and error, and checking how close or far the file name is, to its name-size limit....
at the start i was confused sense the vid name limit had enough, but then i realized the log name is longer sense it include all of it + more, so i realized thats where it failed....