mirror of
https://github.com/bytedance/deer-flow.git
synced 2026-08-13 08:18:57 +00:00
* fix(sandbox): honor single-bound line ranges in read_file read_file only sliced content when BOTH start_line and end_line were provided, so read_file(path, start_line=100) or read_file(path, end_line=50) silently returned the whole file. Handle one-sided ranges: default the missing bound (start->1, end->EOF), clamp start to 1, and return clear messages when start_line exceeds the file length or start_line > end_line. * address review: guard one-sided end_line <= 0 in read_file Add symmetric end_line guard and run the inverted-range check regardless of which bounds are explicit, so a lone end_line<=0 returns a clean error instead of a negative-index slice. Per @willem-bd review on #4078. Co-Authored-By: Claude <noreply@anthropic.com> --------- Co-authored-by: Claude <noreply@anthropic.com>