From 6dc816bebafce8c954f68ca2ba2946b3829fb60e Mon Sep 17 00:00:00 2001 From: rarebuffalo Date: Mon, 15 Jun 2026 01:05:21 +0530 Subject: [PATCH] allow interactive repl launch in offline no-ai mode --- cli/securelens/cli.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/cli/securelens/cli.py b/cli/securelens/cli.py index 5161a6e..b4a98bf 100644 --- a/cli/securelens/cli.py +++ b/cli/securelens/cli.py @@ -299,12 +299,12 @@ async def _scan_async(path, model, output, max_files, ci, fail_on, no_ai, sync): return # ── Interactive REPL ───────────────────────────────────────────────────── - if fmt in ("terminal", "all", "markdown") and not no_ai: + if fmt in ("terminal", "all", "markdown"): ctx = ReplContext( target=str(root), scan_result=result, target_type="code", - api_key=cfg.api_key, + api_key=cfg.api_key if not no_ai else None, model=cfg.default_model, ) await run_repl(ctx) @@ -394,12 +394,12 @@ async def _web_async(url, model, output, ci, fail_on, no_ai): _ci_exit(result.issues, fail_on, "web") return - if fmt in ("terminal", "all", "markdown") and not no_ai: + if fmt in ("terminal", "all", "markdown"): ctx = ReplContext( target=url, scan_result=result, target_type="web", - api_key=cfg.api_key, + api_key=cfg.api_key if not no_ai else None, model=cfg.default_model, ) await run_repl(ctx)