kuse 857eac45cd
fix(agents): treat non-finite read_file line bounds as unusable in loop detection (#5990)
_coerce_line_number() caught only (TypeError, ValueError), but a
model-emitted JSON number such as 1e999 parses to float('inf') and
int(inf) raises OverflowError, which escaped _track_and_check() through
after_model() and crashed the run. Treat the bound as unusable (None),
matching the OverflowError guards already merged for the search-tool
coercers.
2026-09-28 22:37:30 +08:00
..