INNER CODE UNIT · Python
_batch_groups
samugit83/redamon · recon/main.py:99
def _batch_groups() -> list:
"""The operator-approved groups, in run order, or [] outside batch mode.
Read through a function rather than a module constant so a test can point the
settings dict at a different project without re-importing this module.
"""
if not _settings.get('DOMAIN_BATCH_MODE', False):
return []
groups = _settings.get('DOMAIN_BATCH_GROUPS') or []
return groups if isinstance(groups, list) else []
# ---------------------------------------------------------------------------
# Background Graph DB update helper
# ---------------------------------------------------------------------------
# Serialized via max_workers=1 so Neo4j never gets concurrent writes,
# but the main pipeline thread is not blocked.
# Re-created per pipeline run via _graph_reset() to be safe across calls.