MCPcopy Index your code
hub / github.com/algorithmicsuperintelligence/openevolve / _normalize_newlines

Function _normalize_newlines

scripts/manual.py:107–113  ·  view source on GitHub ↗

Normalize CRLF/CR newlines to LF This makes diff parsing deterministic because OpenEvolve diff regexes use '\n'

(text: str)

Source from the content-addressed store, hash-verified

105
106
107def _normalize_newlines(text: str) -> str:
108 """
109 Normalize CRLF/CR newlines to LF
110
111 This makes diff parsing deterministic because OpenEvolve diff regexes use '\n'
112 """
113 return text.replace("\r\n", "\n").replace("\r", "\n").rstrip()
114
115
116def _write_answer(qdir: Path, task_id: str, answer_text: str) -> None:

Callers 1

_write_answerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected