feat: add traceback logging and spec-aligned error message to GeminiEngine (refs #142)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -148,13 +148,15 @@ class GeminiEngine:
|
|||||||
return self._model
|
return self._model
|
||||||
|
|
||||||
except ImportError as exc:
|
except ImportError as exc:
|
||||||
|
logger.exception("Vertex AI SDK import failed")
|
||||||
raise GeminiUnavailableError(
|
raise GeminiUnavailableError(
|
||||||
"google-cloud-aiplatform is not installed. "
|
"google-cloud-aiplatform is not installed. "
|
||||||
"Install with: pip install google-cloud-aiplatform"
|
"Install with: pip install google-cloud-aiplatform"
|
||||||
) from exc
|
) from exc
|
||||||
except Exception as exc:
|
except Exception as exc:
|
||||||
|
logger.exception("Vertex AI authentication failed")
|
||||||
raise GeminiUnavailableError(
|
raise GeminiUnavailableError(
|
||||||
f"Failed to initialize Gemini engine: {exc}"
|
f"Vertex AI authentication failed: {exc}"
|
||||||
) from exc
|
) from exc
|
||||||
|
|
||||||
def extract_maintenance(
|
def extract_maintenance(
|
||||||
|
|||||||
Reference in New Issue
Block a user