MCPcopy Index your code
hub / github.com/RustPython/RustPython / _translate_newlines

Method _translate_newlines

Lib/subprocess.py:1097–1099  ·  view source on GitHub ↗
(self, data, encoding, errors)

Source from the content-addressed store, hash-verified

1095 self.text_mode = bool(universal_newlines)
1096
1097 def _translate_newlines(self, data, encoding, errors):
1098 data = data.decode(encoding, errors)
1099 return data.replace("\r\n", "\n").replace("\r", "\n")
1100
1101 def __enter__(self):
1102 return self

Callers 1

_communicateMethod · 0.95

Calls 2

decodeMethod · 0.45
replaceMethod · 0.45

Tested by

no test coverage detected