From 1170a85eb4232c5b8eedb8d70c2a9a845b66d9cf Mon Sep 17 00:00:00 2001 From: Huy Doan Date: Thu, 2 Apr 2026 18:39:30 +0700 Subject: [PATCH] Fix/brave search api key readonly (#648) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix(secure-cli): resolve ambiguous column in LookupByBinary JOIN query (#641) LookupByBinary uses LEFT JOIN with secure_cli_user_credentials but SELECT columns lacked table alias prefix, causing PostgreSQL error: "column reference 'id' is ambiguous (SQLSTATE 42702)" This silently broke ALL credentialed CLI exec — commands fell through to regular shell exec without injected env vars. Fix: use b.-prefixed column names for JOIN queries. Also add diagnostic logging to lookupCredentialedBinary for future debugging. * fix(agent): defer warning messages after parallel tool results (#644) When parallel tool calls trigger loop detection warnings, the warning messages (role="user") were inserted between tool result messages (role="tool"). This breaks the Anthropic API when routed through OpenAI-compatible proxies (e.g. LiteLLM): the proxy groups consecutive tool messages into a single user message with tool_result blocks, but an intervening user warning splits the group, causing orphaned tool_results and HTTP 400 "tool_use ids without tool_result blocks". Fix: accumulate warning messages during parallel result processing and append them after all tool results, preserving the consecutive grouping. Closes #642 * fix(web): allow editing Brave Search API key when masked --------- Co-authored-by: Viet Tran --- ui/web/src/pages/config/sections/tools-web-section.tsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ui/web/src/pages/config/sections/tools-web-section.tsx b/ui/web/src/pages/config/sections/tools-web-section.tsx index d6cba568..d9375cf1 100644 --- a/ui/web/src/pages/config/sections/tools-web-section.tsx +++ b/ui/web/src/pages/config/sections/tools-web-section.tsx @@ -125,9 +125,7 @@ export function ToolsWebSection({ data, onSave, saving }: Props) { updateNested("web", { brave: { ...brave, api_key: e.target.value } }) }