From 2b60f3df16c66a39dbebd381f4aed3881c31bfbf Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Mon, 25 May 2026 07:03:42 +0000 Subject: [PATCH] style: apply ruff format fixes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: João --- lib/crewai/src/crewai/crew.py | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/lib/crewai/src/crewai/crew.py b/lib/crewai/src/crewai/crew.py index 164020343..2029c3858 100644 --- a/lib/crewai/src/crewai/crew.py +++ b/lib/crewai/src/crewai/crew.py @@ -1132,20 +1132,21 @@ class Crew(FlowTrackable, BaseModel): "warming shared prefix first", ) first_agent, _ = agent_prompts[0] - if hasattr(first_agent, "llm") and hasattr(first_agent.llm, "preload_probe"): + if hasattr(first_agent, "llm") and hasattr( + first_agent.llm, "preload_probe" + ): first_agent.llm.preload_probe(prefix) for agent, prompt in agent_prompts: if hasattr(agent, "llm") and hasattr(agent.llm, "preload_probe"): agent.llm.preload_probe(prompt) return - else: - self._logger.log( - "info", - f"Cache preload: shared prefix too short ({len(prefix)} chars), " - "falling back to parallel strategy", - ) - strategy = "parallel" + self._logger.log( + "info", + f"Cache preload: shared prefix too short ({len(prefix)} chars), " + "falling back to parallel strategy", + ) + strategy = "parallel" if strategy == "parallel": with ThreadPoolExecutor(max_workers=min(len(agent_prompts), 4)) as pool: