MCPcopy Index your code
hub / github.com/algorithmiaio/algorithmia-python / write_to_pipe

Method write_to_pipe

Algorithmia/handler.py:73–80  ·  view source on GitHub ↗
(self, data_string)

Source from the content-addressed store, hash-verified

71 return response_string
72
73 def write_to_pipe(self, data_string):
74 if os.name == "posix":
75 with open(self.FIFO_PATH, 'w') as f:
76 f.write(data_string)
77 f.write('\n')
78 sys.stdout.flush()
79 if os.name == "nt":
80 sys.stdin = data_string
81
82 def serve(self):
83 try:

Callers 1

serveMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected