fix(ops): оповещения уходят в тему «алерты», а не в переговорку (#2203) #3129
1 changed files with 1 additions and 1 deletions
|
|
@ -69,7 +69,7 @@ def _posix(path: Path) -> str:
|
||||||
def _extract_notify(script: Path) -> str:
|
def _extract_notify(script: Path) -> str:
|
||||||
"""Вырезать тело notify() из настоящего файла — от заголовка до `}` в нулевой колонке."""
|
"""Вырезать тело notify() из настоящего файла — от заголовка до `}` в нулевой колонке."""
|
||||||
lines = script.read_text(encoding="utf-8").splitlines()
|
lines = script.read_text(encoding="utf-8").splitlines()
|
||||||
start = next((i for i, l in enumerate(lines) if l.startswith("notify()")), None)
|
start = next((i for i, ln in enumerate(lines) if ln.startswith("notify()")), None)
|
||||||
assert start is not None, f"{script.name}: не нашёл notify() — отправитель переименован"
|
assert start is not None, f"{script.name}: не нашёл notify() — отправитель переименован"
|
||||||
end = next((i for i in range(start + 1, len(lines)) if lines[i] == "}"), None)
|
end = next((i for i in range(start + 1, len(lines)) if lines[i] == "}"), None)
|
||||||
assert end is not None, f"{script.name}: не нашёл конец notify()"
|
assert end is not None, f"{script.name}: не нашёл конец notify()"
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue