ingest.py: guard Stage 2 enqueue behind SKIP_STAGE2_ENQUEUE env var for migration runs

This commit is contained in:
2026-04-30 16:20:11 +00:00
parent c08f57a6f2
commit 2fb50cce71
+3 -1
View File
@@ -143,7 +143,9 @@ def ingest_file(filepath):
print(f" Indexed {len(chunks)} chunks: {path.name}")
# Enqueue for Stage 2 → Stage 3 (Graphiti pipeline)
enqueue_stage2(path.name, text)
# SKIP_STAGE2_ENQUEUE env var set by migration scripts to prevent bulk enqueue
if not os.getenv("SKIP_STAGE2_ENQUEUE"):
enqueue_stage2(path.name, text)
return len(chunks)