The agent struggled and eventually suggested sending a bug report it created – here it is.
Bug Report: File Editing Tool Inconsistency with Large Content Changes
Issue Description
The file editing tool (edit_file) fails inconsistently when attempting to write large amounts of content to a file in a single operation. However, the same content can be successfully added when broken down into smaller, incremental changes.
Steps to Reproduce
-
Attempt to create or edit a file with a large amount of content (approximately 500+ lines) in a single edit_file operation
-
Observe that the operation fails with a generic error message: “Error: no result from tool. The user likely interrupted the tool call to send you a message.”
-
Break down the same content into smaller chunks (approximately 100-200 lines each)
-
Observe that each smaller chunk can be successfully added to the file
Expected Behavior
The tool should be able to handle larger content changes in a single operation, or at minimum provide a more descriptive error message indicating size limitations.
Actual Behavior
-
Large content changes fail silently or with a generic error message
-
No indication of size limitations or other constraints is provided
-
The tool works reliably with smaller, incremental changes
Reproduction Example
We attempted to create a markdown document with implementation details (approximately 800 lines total). When trying to create the entire document at once, the operation failed repeatedly. When we broke it down into sections of approximately 100-200 lines each, each section was added successfully.
Environment Information
-
OS: Windows 10 (10.0.19045)
-
Workspace path: /c%3A/Users/■■■/code/dreamstait
-
Shell: C:\Program Files\PowerShell\7\pwsh.exe
Additional Notes
-
The tool seems to work more consistently when all three parameters (target_file, instructions, and code_edit) are provided
-
There appears to be no clear pattern to the size limitation - sometimes moderately large edits work, while other times they fail
-
A clearer error message indicating size limitations would be helpful for users to understand how to structure their edit requests
Suggested Improvements
-
Increase the maximum size limit for file edits
-
Provide specific error messages indicating size limitations
-
Add documentation about size constraints
-
Implement automatic chunking for large edits
-
Add a progress indicator for large file operations