chore: remove unused file and comments
All checks were successful
Build and Push Docker Images / build (push) Successful in 36s

Signed-off-by: UdoChudo <stream@udochudo.ru>
This commit is contained in:
Udo Chudo 2025-06-20 15:05:30 +05:00
parent e55e330c50
commit 4f7300e2ce
2 changed files with 0 additions and 25 deletions

View File

@ -1,22 +1,5 @@
# parser.py
# def parse_region_id(host: str) -> int | None:
# """
# Извлекает region_id из строки host.
# Формат: p<region><...>, например p18ecpapp01 → region_id = 18
#
# Returns:
# int | None: номер региона или None
# """
# if not host or not host.startswith("p"):
# return None
#
# match = re.match(r"^p(\d+)", host)
# if match:
# return int(match.group(1))
# return None
def parse_region_id(hostgroups: str | None) -> str:
if not hostgroups:
return "0"

View File

@ -1,8 +0,0 @@
from .parser import parse_region_id
from .db_utils import get_recipients_by_features
from app import Systems
async def get_recipients_from_data(data: dict, flask_app) -> list[int]:
system_names = [sys.system_name for sys in Systems.query.all()]
parsed = parse_message(data, system_names)
return get_recipients_by_features(parsed, flask_app)