diff --git a/evalharness/cli.py b/evalharness/cli.py index 91ed8fc..e573988 100644 --- a/evalharness/cli.py +++ b/evalharness/cli.py @@ -478,7 +478,11 @@ def _cmd_eval_run(args) -> int: _print_phase(console, i + 1, total_runs, name, 'loading/downloading dataset') ds = get_dataset(name, **overrides) + if _shared_reporter is not None: + _shared_reporter.pause() # let hub tqdm print cleanly sample_count = len(ds) + if _shared_reporter is not None: + _shared_reporter.resume() origin = ds.lineage.get('from', 'unknown') _print_phase(console, i + 1, total_runs, name, f'dataset ready · samples={sample_count} · source={origin}') diff --git a/evalharness/progress/rich_terminal.py b/evalharness/progress/rich_terminal.py index 006661d..52f0a49 100644 --- a/evalharness/progress/rich_terminal.py +++ b/evalharness/progress/rich_terminal.py @@ -151,6 +151,16 @@ class RichTerminalProgress: else: self.console.print(message) + def pause(self): + """Temporarily stop the live display (e.g. while hub downloads print + their own tqdm); task state is kept and resume() restores the bars.""" + if self.task_id is not None or self.overall_id is not None: + self.progress.stop() + + def resume(self): + if self.task_id is not None or self.overall_id is not None: + self.progress.start() + def close(self): if self.task_id is not None: if self.heartbeat_task is not None: