From 7753eceb3b474a5047b20f82d35db3aaec511b16 Mon Sep 17 00:00:00 2001 From: Alexander Tarasov Date: Tue, 12 Aug 2025 10:42:58 +0300 Subject: [PATCH] get_file now raises FileNotFoundError instead of FileExistError --- viking_file/clients/client_async.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/viking_file/clients/client_async.py b/viking_file/clients/client_async.py index 6877544..ad5dd33 100644 --- a/viking_file/clients/client_async.py +++ b/viking_file/clients/client_async.py @@ -241,7 +241,7 @@ class AsyncVikingClient: File: The file information. Raises: - FileExistsError: If the file does not exist. + FileNotFoundError: If the file does not exist. """ file_hash = self._get_file_hash(file) @@ -260,7 +260,7 @@ class AsyncVikingClient: downloads=api_response_json.get("downloads") ) else: - raise FileExistsError(f"File {file_hash} does not exist") + raise FileNotFoundError(f"File {file_hash} does not exist") async def rename_file(self, file: File | str, new_filename: str): """