From faa4046fecaf3d56744bf98239072dab9b5e8f57 Mon Sep 17 00:00:00 2001 From: Mizev Andrew <150728785+carpalsgrabby@users.noreply.github.com> Date: Tue, 25 Nov 2025 09:53:15 +0100 Subject: [PATCH] Add --quiet-errors to suppress per-fanout error spam --- sweep_layouts.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/sweep_layouts.py b/sweep_layouts.py index 159ea49..a90c953 100644 --- a/sweep_layouts.py +++ b/sweep_layouts.py @@ -64,6 +64,12 @@ def parse_args() -> argparse.Namespace: action="store_true", help="Also dump raw JSON lines for each configuration.", ) + p.add_argument( + "--quiet-errors", + action="store_true", + help="Suppress per-fanout error messages from app.py.", + ) + return parser.parse_args() @@ -146,8 +152,10 @@ def main() -> None: for fanout in args.fanouts: try: data = run_app(app_path, leaves, args.style, fanout) - except Exception as e: # noqa: BLE001 - print(f"ERROR: {e}", file=sys.stderr) + except Exception as e: # noqa: BLE001 + if not args.quiet_errors: + print(f"ERROR for fanout={f}: {e}", file=sys.stderr) + continue # keys are based on README description; tweak if you change app.py