MCPcopy Index your code
hub / github.com/python/cpython / write

Method write

Lib/idlelib/run.py:474–478  ·  view source on GitHub ↗
(self, s)

Source from the content-addressed store, hash-verified

472 return True
473
474 def write(self, s):
475 if self.closed:
476 raise ValueError("write to closed file")
477 s = str.encode(s, self.encoding, self.errors).decode(self.encoding, self.errors)
478 return self.shell.write(s, self.tags)
479
480
481class StdInputFile(StdioFile):

Callers 4

test_writeMethod · 0.95
test_closeMethod · 0.95
idle_showwarning_subprocFunction · 0.45

Calls 2

decodeMethod · 0.45
encodeMethod · 0.45

Tested by 3

test_writeMethod · 0.76
test_closeMethod · 0.76