cellmap_flow.logging_setup ========================== .. py:module:: cellmap_flow.logging_setup .. autoapi-nested-parse:: One logging format, actually applied. ``logging.basicConfig`` does nothing once the root logger has a handler, and ``cellmap_flow.globals`` configures it at import time -- and nearly everything used to import that early. So every later ``basicConfig`` call in a CLI was a silent no-op: ``yaml_cli`` has been asking for a timestamped format for a while, and the output has always come out as the bare default:: INFO:cellmap_flow.cli.yaml_cli:Loading configuration from: ... with no time on it, which is no help at all when the question is which step took four minutes. ``finetune_cli`` is the one place that passed ``force=True``, which is why training logs have timestamps and nothing else does. Anything that wants to set the format has to pass ``force=True``, and should use the same format while doing it. That is all this module is. Attributes ---------- .. autoapisummary:: cellmap_flow.logging_setup.LOG_FORMAT cellmap_flow.logging_setup.LOG_DATEFMT Functions --------- .. autoapisummary:: cellmap_flow.logging_setup.configure_logging Module Contents --------------- .. py:data:: LOG_FORMAT :value: '%(asctime)s %(levelname)s %(name)s: %(message)s' .. py:data:: LOG_DATEFMT :value: '%Y-%m-%d %H:%M:%S' .. py:function:: configure_logging(level=logging.INFO) Install the shared timestamped format, replacing any earlier config. ``force=True`` is the point: without it this is a no-op in every process that has already imported ``cellmap_flow.globals``.