mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-08 11:17:27 +00:00
15 lines
516 B
Python
15 lines
516 B
Python
from typing import BinaryIO, List
|
|
|
|
from backend.condition.parsing.parser import Parser
|
|
from utils.logger import setup_logger
|
|
from backend.condition.file_type import FileType, detect_file_type
|
|
from backend.condition.parsing.factory import select_parser
|
|
|
|
def process_file(file_stream: BinaryIO, source_key: str) -> None:
|
|
print(f"[processor] Received file: {source_key}")
|
|
|
|
# Instantiation
|
|
file_type: FileType = detect_file_type(source_key)
|
|
parser: Parser = select_parser(file_type)
|
|
|
|
# Orchestration
|