docs: def handle_error(self):
          """Tries to send an 500 error after encountering an exception."""
          if self.server.can_ignore_error(self):
              return
          if thread_local.status_code is None:
              msg("ERROR: Cannot send error status code! " +
                  "Header already sent!\n{0}", traceback.format_exc())
          else:
              msg("ERROR: Error while processing request:\n{0}",
                  traceback.format_exc())
              try:
                  self.send_error(500, "Internal Error")
              except:  # nopep8
                  if self.server.can_ignore_error(self):
                      return
                  msg("ERROR: Cannot send error status code:\n{0}",
                      traceback.format_exc())