Перенос LogManager в v2 и обновление документации. Обновлены импорты и исправлены ссылки на LogManager в README и тестах. Удалены устаревшие типы и рефакторинг конфигурации управления.

This commit is contained in:
2026-02-26 20:37:00 +03:00
parent 7b5d6d2156
commit aa32c23dba
22 changed files with 168 additions and 143 deletions

View File

@@ -1,6 +1,6 @@
import asyncio
from config_manager.v2 import ConfigManagerV2, ManagementServerSettings
from config_manager.v2 import ConfigManagerV2
from config_manager.v2.control.base import ControlChannel, StartHandler, StatusHandler, StopHandler
@@ -33,14 +33,10 @@ class ControlledApp(ConfigManagerV2):
def test_control_channel_can_stop_manager(tmp_path):
async def scenario() -> None:
cfg = tmp_path / "config.yaml"
cfg.write_text("log: {}\n", encoding="utf-8")
cfg.write_text("log: {}\nmanagement: { enabled: false }\n", encoding="utf-8")
channel = DummyControlChannel()
app = ControlledApp(
str(cfg),
control_channel=channel,
management_settings=ManagementServerSettings(enabled=False),
)
app = ControlledApp(str(cfg), control_channel=channel)
runner = asyncio.create_task(app.start())
await asyncio.sleep(0.12)