# fixhunt regression fixture: ruff FURB129, ruff 0.17.1 # the fix labelled safe changes the program's output on this program # before the fix: no stdout, exit 0 # after the fix: no stdout, timed out # finding 2026-10-17T21-30-17-728Z-bxl4-ruff-FURB129/r2-p002; rule fired 1 time(s) before the fix def main(): with open('tmp.txt', 'w') as f: f.write('0\n1\n2') with open('tmp.txt') as fp: for line in fp.readlines(): fp.seek(0) if __name__ == '__main__': main()