code: def write(self, data):
      with memoryview(data) as m:
          total_count = m.nbytes
          while total_count > 0:
              try:
                  nbytes = __try_op__(
                      "send",
                      self._sock.send,
                      WRITE_RETRY,
                      m[:MAX_MSG_SIZE],
                  )
                  m = m[nbytes:]
                  total_count -= nbytes
              except socket.timeout:
                  continue
              except socket.error as e:
                  self.close()
                  raise EOFError(e)
  
file_path: metaflow/metaflow/plugins/env_escape/communication/socket_bytestream.py
imports: import errno
  import socket
  import sys
  from .bytestream import ByteStream
  from .utils import __try_op__
label_desc: Use image node_id 5 for calling the SocketByteStream obj's underlying member method code with example usage: obj.write(data) without return types