fix name of function

pull/32736/head
Shane Smiskol 12 months ago
parent 47bb3ec100
commit 3eddcd4d9d
  1. 8
      system/athena/athenad.py

@ -104,7 +104,7 @@ cancelled_uploads: set[str] = set()
cur_upload_items: dict[int, UploadItem | None] = {}
def strip_zstd_extension(fn: str) -> str:
def strip_zst_extension(fn: str) -> str:
if fn.endswith('.zst'):
return fn[:-4]
return fn
@ -285,8 +285,8 @@ def _do_upload(upload_item: UploadItem, callback: Callable = None) -> requests.R
compress = False
# If file does not exist, but does exist without the .zst extension we will compress on the fly
if not os.path.exists(path) and os.path.exists(strip_zstd_extension(path)):
path = strip_zstd_extension(path)
if not os.path.exists(path) and os.path.exists(strip_zst_extension(path)):
path = strip_zst_extension(path)
compress = True
with open(path, "rb") as f:
@ -376,7 +376,7 @@ def uploadFilesToUrls(files_data: list[UploadFileDict]) -> UploadFilesToUrlRespo
continue
path = os.path.join(Paths.log_root(), file.fn)
if not os.path.exists(path) and not os.path.exists(strip_zstd_extension(path)):
if not os.path.exists(path) and not os.path.exists(strip_zst_extension(path)):
failed.append(file.fn)
continue

Loading…
Cancel
Save