diff --git a/nextcloud_mcp_server/cli.py b/nextcloud_mcp_server/cli.py index f247a1cd..9f1d2283 100644 --- a/nextcloud_mcp_server/cli.py +++ b/nextcloud_mcp_server/cli.py @@ -291,16 +291,9 @@ def run( def _init_worker_observability(settings: Settings) -> None: - """Configure logging, metrics, and tracing for the ingest worker. - - Mirrors the observability bootstrap the API pod performs in its lifespan - (``app.py``), but for the standalone ``worker`` entrypoint which never runs - uvicorn. Without this the worker emits plain-text logs and serves no - ``/metrics`` endpoint, so the astrolabe_* document-pipeline metrics and the - ``document_processor.parse`` spans (recorded in the shared registry/processor - code the worker executes) stay invisible in external split-worker mode - (Deck #310 / #175). - """ + """Configure logging, metrics, and tracing for the standalone ingest worker.""" + # Mirrors app.py's lifespan bootstrap; without it the worker's astrolabe_* + # metrics and document_processor.parse spans are invisible in external mode. # Structured logging first, so every subsequent startup line is JSON like # the API's — the worker entrypoint never went through uvicorn's log_config. setup_logging( diff --git a/tests/test_cli.py b/tests/test_cli.py index 638e62ae..87c006b6 100644 --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -339,7 +339,7 @@ def _fake_settings(**overrides): real Settings.__post_init__ validation/derivation. """ base = dict( - ingest_queue="postgres", + ingest_queue="postgres", # for realism / worker() gating; unused by the helper log_format="json", log_level="INFO", log_include_trace_context=True,