2023-05-15 08:51:32 +08:00
|
|
|
from services.errors.base import BaseServiceError
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class FileNotExistsError(BaseServiceError):
|
|
|
|
|
pass
|
2023-09-27 16:06:32 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
class FileTooLargeError(BaseServiceError):
|
|
|
|
|
description = "{message}"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class UnsupportedFileTypeError(BaseServiceError):
|
|
|
|
|
pass
|
2025-11-04 15:45:22 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
class BlockedFileExtensionError(BaseServiceError):
|
|
|
|
|
description = "File extension '{extension}' is not allowed for security reasons"
|