StefanLobbenmeier / youtube-dl-gui

A cross-platform GUI for youtube-dl made in Electron and node.js
GNU Affero General Public License v3.0
1.55k stars 62 forks source link

Audio download greater than 100% #21

Closed chipsenkbeil closed 1 year ago

chipsenkbeil commented 1 year ago

Describe the bug Percentage of download is greater than 100% for some audio.

To Reproduce Steps to reproduce the behavior:

  1. Download videos for https://www.youtube.com/@Mony514 (video from screenshot)
  2. Examine audio output percentage for some of them is greater than 100%

Expected behavior Does not exceed 100%.

Screenshots

image

Additional info (please complete the following information):

Additional context I enabled subtitles for all of the videos, if that possibly impacts the percentage.

StefanLobbenmeier commented 1 year ago

I Wonder if this is some weird effect from https://github.com/StefanLobbenmeier/youtube-dl-gui/pull/12

anyway, I will take a look at the logs from the download, we get the progress % directly from yt-dlp output, so if it gives us a higher percentage there then we display it

StefanLobbenmeier commented 1 year ago

Just gave it 2 tries with your video, once without subtitles and then with.

Did not notice the percentage going above 100%, also not in the logs:

[download] 100.0% 2.55MiB/s  {"downloaded_bytes": 22916700, "total_bytes": 22916700, "filename": "C:\\Users\\Stefan\\Downloads\\Mony Mony\\Master Keaton Episode 35-(240p24).f140.m4a", "status": "finished", "elapsed": 8.558793067932129, "ctx_id": null, "speed": 2677562.106959183, "_speed_str": "2.55MiB/s", "_total_bytes_str": "  21.86MiB", "_elapsed_str": "00:00:08", "_percent_str": "100.0%", "_default_template": "100% of   21.86MiB in 00:00:08 at 2.55MiB/s"}                                                                                                                                                                                                                                            
[Merger] Merging formats into "C:\Users\Stefan\Downloads\Mony Mony\Master Keaton Episode 35-(240p24).mkv"
[EmbedSubtitle] Embedding subtitles in "C:\Users\Stefan\Downloads\Mony Mony\Master Keaton Episode 35-(240p24).mkv"
Download finished

So it seems to work as excepted now. The App only parses the output from the logs, so it might be that yt-dlp sometimes prints a higher number for some reason. If you can reproduce it again, please include the logs from the download