fix(ssl): run CA guard during agent initialization

This commit is contained in:
Teknium
2026-06-13 21:14:32 -07:00
parent af5b526472
commit dc90ca4e17
3 changed files with 4 additions and 2 deletions
+3
View File
@@ -900,6 +900,9 @@ def init_agent(
agent.api_key = client_kwargs.get("api_key", "")
agent.base_url = client_kwargs.get("base_url", agent.base_url)
try:
from agent.ssl_guard import verify_ca_bundle_with_fallback
verify_ca_bundle_with_fallback()
agent.client = agent._create_openai_client(client_kwargs, reason="agent_init", shared=True)
if not agent.quiet_mode:
print(f"🤖 AI Agent initialized with model: {agent.model}")