Skip to content

Commit

Permalink
Increase maximum upload video file size limit to 4GiB
Browse files Browse the repository at this point in the history
Updated the `get_upload_videos` function to support video files up to 4GiB from the previous limit of 2000MiB. Adjusted the corresponding warning message to reflect the new file size threshold.

Signed-off-by: hldh214 <[email protected]>
  • Loading branch information
hldh214 committed Aug 15, 2024
1 parent dda0035 commit 1bf5a03
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions recorder/uploader.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def init_spankbang():
def get_upload_videos(
source_type,
filesize_min=1024 * 1024 * 64,
filesize_max=1024 * 1024 * 2000,
filesize_max=1024 * 1024 * 1024 * 4,
should_delete_small_files=True
):
video_path = pathlib.Path(
Expand All @@ -102,7 +102,7 @@ def get_upload_videos(
delete_files.append(file)
continue
if filesize > filesize_max:
logger.warning(f'{file}: {sizeof_fmt(filesize)} > 2000MiB, skip')
logger.warning(f'{file}: {sizeof_fmt(filesize)} > 4GiB, skip')
continue

path = pathlib.Path(file)
Expand Down

0 comments on commit 1bf5a03

Please sign in to comment.