From d30c3806bbe4250f3feda12ada18a7abf7520b15 Mon Sep 17 00:00:00 2001 From: rzhxeo Date: Fri, 21 Feb 2014 00:23:17 +0100 Subject: [PATCH] Floor instead of round in format_percent --- youtube_dl/downloader/common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/youtube_dl/downloader/common.py b/youtube_dl/downloader/common.py index 5a068aa8b..c21ee3caa 100644 --- a/youtube_dl/downloader/common.py +++ b/youtube_dl/downloader/common.py @@ -70,7 +70,7 @@ class FileDownloader(object): def format_percent(percent): if percent is None: return '---.-%' - return '%6s' % ('%3.1f%%' % percent) + return '%3s.%.1s%%' % tuple(str(float(percent)).split('.')) @staticmethod def calc_eta(start, now, total, current):