mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2026-04-06 07:47:53 +10:00
Relax archive output readiness check
This commit is contained in:
@@ -207,6 +207,18 @@ def wait_for_archive_outputs(
|
||||
fallback = Path(snapshot.output_dir, 'index.jsonl')
|
||||
if fallback.exists():
|
||||
output_rel = 'index.jsonl'
|
||||
if output_rel is None:
|
||||
snapshot_dir = Path(snapshot.output_dir)
|
||||
for candidate in snapshot_dir.rglob('*'):
|
||||
if not candidate.is_file():
|
||||
continue
|
||||
rel_path = candidate.relative_to(snapshot_dir)
|
||||
if rel_path.parts and rel_path.parts[0] == 'responses':
|
||||
continue
|
||||
if rel_path.name in {'stdout.log', 'stderr.log', 'cmd.sh'}:
|
||||
continue
|
||||
output_rel = str(rel_path)
|
||||
break
|
||||
if output_rel is None:
|
||||
raise SystemExit(1)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user