diff --git a/.claude/settings.local.json b/.claude/settings.local.json index 2398331..dd6b538 100644 --- a/.claude/settings.local.json +++ b/.claude/settings.local.json @@ -19,7 +19,11 @@ "Bash(python3 -c \":*)", "Bash(python -c ':*)", "Bash(node_modules/.bin/tsc --noEmit)", - "Bash(./node_modules/.bin/tsc --noEmit)" + "Bash(./node_modules/.bin/tsc --noEmit)", + "Bash(python -m py_compile \"C:/Users/Professional/Documents/VSCode/utp_service/backend/app/services/sse.py\")", + "Bash(python -m py_compile \"C:/Users/Professional/Documents/VSCode/utp_service/backend/app/services/discovery/orchestrator.py\")", + "Bash(python -m py_compile \"C:/Users/Professional/Documents/VSCode/utp_service/backend/app/services/discovery/config_parser.py\")", + "Bash(python -m py_compile \"C:/Users/Professional/Documents/VSCode/utp_service/backend/app/routers/objects.py\")" ] } } diff --git a/backend/app/services/discovery/orchestrator.py b/backend/app/services/discovery/orchestrator.py index 1232139..2a8c5ed 100644 --- a/backend/app/services/discovery/orchestrator.py +++ b/backend/app/services/discovery/orchestrator.py @@ -172,7 +172,7 @@ async def discover_via_ssh( except Exception as exc: # Session is now invalid after a failed flush — capture the error so we can # still emit disc_rack_done before propagating and aborting discovery. - _flush_error = RuntimeError(f"DB flush failed after rack {rack_host}: {exc}") from exc + _flush_error = exc except Exception as exc: # Unexpected per-rack error (e.g. SSH timeout, config parse failure not caught @@ -188,7 +188,7 @@ async def discover_via_ssh( }) if _flush_error: - raise _flush_error + raise RuntimeError(f"DB flush failed after rack {rack_host}: {_flush_error}") from _flush_error # ── Phase 2.5: Slave rack discovery via ARP ─────────────────────────────── all_rack_ips_set = {h for _, h, _, _ in rack_hosts}