Add message when validate failure.
967487
protected void addError(String errorKey, String errorMessage) {
		invalid = true;
		controller.setAttr(errorKey, errorMessage);
		if (shortCircuit) {
			throw new ValidateException();
		}
	}
755982
protected function onInValid()
    {
        // We disable this standard error message as we are not changing anything here
        //$this->addMessage(sprintf($this->_('Input error! Changes to %s not saved!'), $this->getTopic()));

        if ($this->_csrf) {
            if ($this->_csrf->getMessages()) {
                $this->addMessage($this->_('The form was open for too long or was opened in multiple windows.'));
            }
        }
    }
625931
def failed(self, fail_on_warnings=True):
        """"""

        return bool(self.errors) or (fail_on_warnings and bool(self.warnings))
159119
def fail(self, message, param=None, ctx=None):
        """"""
        raise BadParameter(message, ctx=ctx, param=param)
1330284
def addFailure(self, test, err):
        
        super().addFailure(test, err)
        self.test_info(test)
        self._call_test_results('addFailure', test, err)
58475
def _on_process_error(self, error):
        
        if self is None:
            return
        err = PROCESS_ERROR_STRING[error]
        self._formatter.append_message(err + '\r\n', output_format=OutputFormat.ErrorMessageFormat)
195460
public function addValidationError($field, $errorMessage)
    {
        $this->_isValid = false;
        $this->_validationErrors[$field] = $errorMessage;
    }
675952
function(err) {
            var msg = angular.isString(err) ? err : (err.message || err.data || err.statusText);
            $log.warn(msg);
            reject(err);
          }
760536
def _add_error(self, message):
        """"""
        error_line = Result(False, None, message, Directive(""))
        self._suite.addTest(Adapter(self._filename, error_line))
588934
public void addError(String message, DiagnosticPosition pos) {
		ast.printMessage(Diagnostic.Kind.ERROR, message, null, pos, true);
	}
699370
protected function addErrorFlashMessage()
    {
        $errorFlashMessage = $this->getErrorFlashMessage();
        if ($errorFlashMessage !== false) {
            $this->flashMessageContainer->addMessage($errorFlashMessage);
        }
    }
697831
def _emit_error(cls, message):
        """"""
        sys.stderr.write('ERROR: {message}\n'.format(message=message))
        sys.stderr.flush()
1123533
public void onFailure(Throwable t)
    {
        MessagingService.instance().sendOneWay(new SyncComplete(desc, request.src, request.dst, false).createMessage(), request.initiator);
    }
1254571
def handleError(self, error_code, message):
        ''''''
        self._fail = True
        self.reason = error_code
        self._error = message
349464
public void addErrorMsgs(final Set<String> msgs) {
    if (msgs != null) {
      this._errorMsgs.addAll(msgs);
      if (!msgs.isEmpty()) {
        this._status = ValidationStatus.ERROR;
      }
    }
  }
889766
def _dispatch_validation_error(self, msg, writing=False):
        
        if writing:
            raise IOError(msg)
        else:
            warnings.warn(msg)
435189
def raise_error(self, message='', errors=None, field_name=None):
        
        field_name = field_name if field_name else self.field_name
        raise ValidationError(message, errors=errors, field_name=field_name)