parameters: (self)
docstring: Use a blocking stdin read
docstring_summary: Use a blocking stdin read
docstring_tokens: Use a blocking stdin read
function: def _stdin_raw_block(self):
          """Use a blocking stdin read"""
          # The big problem with the blocking read is that it doesn't
          # exit when it's supposed to in all contexts. An extra
          # key-press may be required to trigger the exit.
          try:
              data = sys.stdin.read(1)
              data = data.replace('\r', '\n')
              return data
          except WindowsError as we:
              if we.winerror == ERROR_NO_DATA:
                  # This error occurs when the pipe is closed
                  return None
              else:
                  # Otherwise let the error propagate
                  raise we
function_tokens: def _stdin_raw_block ( self ) : # The big problem with the blocking read is that it doesn't # exit when it's supposed to in all contexts. An extra # key-press may be required to trigger the exit. try : data = sys . stdin . read ( 1 ) data = data . replace ( '\r' , '\n' ) return data except WindowsError as we : if we . winerror == ERROR_NO_DATA : # This error occurs when the pipe is closed return None else : # Otherwise let the error propagate raise we