Skip to content

Commit d018c30

Browse files
samhvw8daniel-lxs
andcommitted
Update src/core/tools/readFileTool.ts
Co-authored-by: Daniel <[email protected]>
1 parent af05c5c commit d018c30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/core/tools/readFileTool.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -500,7 +500,7 @@ export async function readFileTool(
500500
// Check if adding this image would exceed total memory limit
501501
const imageSizeInMB = imageStats.size / (1024 * 1024)
502502
if (totalImageMemoryUsed + imageSizeInMB > maxTotalImageMemory) {
503-
const notice = `Image skipped to prevent memory issues. Total image memory would exceed ${maxTotalImageMemory}MB limit (current: ${totalImageMemoryUsed.toFixed(1)}MB, this file: ${imageSizeInMB.toFixed(1)}MB). Consider reading fewer images at once or reducing image sizes.`
503+
const notice = `Image skipped to avoid memory limit (${maxTotalImageMemory}MB). Current: ${totalImageMemoryUsed.toFixed(1)}MB + this file: ${imageSizeInMB.toFixed(1)}MB. Try fewer or smaller images.`;
504504

505505
// Track file read
506506
await cline.fileContextTracker.trackFileContext(relPath, "read_tool" as RecordSource)

0 commit comments

Comments
 (0)