code: def no_block_read(output):
      
      _buffer = ""
      if not fcntl:
          return _buffer
  
      o_fd = output.fileno()
      o_fl = fcntl.fcntl(o_fd, fcntl.F_GETFL)
      fcntl.fcntl(o_fd, fcntl.F_SETFL, o_fl | os.O_NONBLOCK)
      try:
          _buffer = output.read()
      except Exception:  # pylint: disable=broad-except
          pass
  
      return _buffer
docs: Try to read a file descriptor in a non blocking mode
  
      If the fcntl is available (unix only) we try to read in a
      asynchronous mode, so we won't block the PIPE at 64K buffer
      (deadlock...)
  
      :param output: file or socket to read from
      :type output: file
      :return: data read from fd
      :rtype: str