diff --git a/drive/app/benchmark/_lib.py b/drive/app/benchmark/_lib.py index 3037b7d7..02c2556f 100644 --- a/drive/app/benchmark/_lib.py +++ b/drive/app/benchmark/_lib.py @@ -24,7 +24,7 @@ def random_date() -> datetime: def random_str() -> str: - return ''.join(random.choices(_STR_LIST, k=64)) + return "".join(random.choices(_STR_LIST, k=64)) def random_private() -> dict[str, str]: diff --git a/drive/app/lib.py b/drive/app/lib.py index ba0c0b4a..8092c620 100644 --- a/drive/app/lib.py +++ b/drive/app/lib.py @@ -12,9 +12,7 @@ def get_daily_usage(drive: Drive) -> int: now = datetime.now(UTC) yesterday = now - timedelta(days=1) dsn = _get_dsn(drive) - return get_uploaded_size( - dsn, int(yesterday.timestamp()), int(now.timestamp()) - ) + return get_uploaded_size(dsn, yesterday, now) def _get_dsn(drive: Drive) -> str: