From 28dcded7ced04b6afee431914947fc022c1be141 Mon Sep 17 00:00:00 2001 From: joyfuI <1342862+joyfuI@users.noreply.github.com> Date: Thu, 5 May 2022 21:43:57 +0900 Subject: [PATCH] =?UTF-8?q?Unknown=20format=20code=20'd'=20for=20object=20?= =?UTF-8?q?of=20type=20'float'=20=EC=98=A4=EB=A5=98=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- logic_normal.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/logic_normal.py b/logic_normal.py index 0f014f9..3648921 100644 --- a/logic_normal.py +++ b/logic_normal.py @@ -311,11 +311,11 @@ class LogicNormal(object): ) data[ "percent" - ] = f"{float(youtube_dl.progress_hooks['downloaded_bytes']) / float(youtube_dl.progress_hooks['total_bytes']) * 100:.2f}" + ] = f"{(float(youtube_dl.progress_hooks['downloaded_bytes']) / float(youtube_dl.progress_hooks['total_bytes']) * 100):.2f}" data["start_time"] = youtube_dl.start_time.strftime("%m-%d %H:%M:%S") data[ "download_time" - ] = f"{download_time.seconds / 60:02f}:{download_time.seconds % 60:02f}" + ] = f"{int(download_time.seconds / 60):02d}:{int(download_time.seconds % 60):02d}" return data except Exception as error: logger.error("Exception:%s", error)