code: def read_all(self):
          
          self.process_rawq()
          while not self.eof:
              self.fill_rawq()
              self.process_rawq()
          buf = self.cookedq.getvalue()
          self.cookedq.seek(0)
          self.cookedq.truncate()
          return buf
docs: Read all data until EOF; block until connection closed.