fix: EditTool can clobber human edits to the same file. (#3043)

Co-authored-by: Colt McAnlis <colton@google.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
This commit is contained in:
Colt McAnlis
2025-07-07 10:28:56 -07:00
committed by GitHub
parent 229ae03631
commit 8f4046c71a
7 changed files with 249 additions and 21 deletions

View File

@@ -13,3 +13,11 @@ export function isFunctionResponse(content: Content): boolean {
content.parts.every((part) => !!part.functionResponse)
);
}
export function isFunctionCall(content: Content): boolean {
return (
content.role === 'model' &&
!!content.parts &&
content.parts.every((part) => !!part.functionCall)
);
}