code: def dispatch_write(self, buf):
          
          if self.state != STATE_DEAD and self.enabled:
              super().dispatch_write(buf)
              return True
          return False
docs: There is new stuff to write when possible