handler, positive on internal error
516646
public int start()
    {
        int rc = 0;

        timers.addAll(newTimers);
        newTimers.clear();

        //  Recalculate all timers now
        for (STimer timer : timers) {
            timer.when = timer.delay + System.currentTimeMillis();
        }

        //  Main reactor loop
        while (!Thread.currentThread().isInterrupted()) {
            if (dirty) {
                // If s_rebuild_pollset() fails, break out of the loop and
                // return its error
                rebuild();
            }
            long wait = ticklessTimer();

            rc = pollset.poll(wait);

            if (rc == -1) {
                if (verbose) {
                    System.out.printf("I: zloop: interrupted (%d)\n", rc);
                }
                rc = 0;
                break; //  Context has been shut down
            }
            //  Handle any timers that have now expired
            Iterator<STimer> it = timers.iterator();
            while (it.hasNext()) {
                STimer timer = it.next();
                if (System.currentTimeMillis() >= timer.when && timer.when != -1) {
                    if (verbose) {
                        System.out.println("I: zloop: call timer handler");
                    }
                    rc = timer.handler.handle(this, null, timer.arg);
                    if (rc == -1) {
                        break; //  Timer handler signaled break
                    }
                    if (timer.times != 0 && --timer.times == 0) {
                        it.remove();
                    }
                    else {
                        timer.when = timer.delay + System.currentTimeMillis();
                    }
                }
            }
            if (rc == -1) {
                break; // Some timer signalled break from the reactor loop
            }

            //  Handle any pollers that are ready
            for (int itemNbr = 0; itemNbr < pollSize; itemNbr++) {
                SPoller poller = pollact[itemNbr];
                if (pollset.getItem(itemNbr).isError()) {
                    if (verbose) {
                        System.out.printf(
                                          "I: zloop: can't poll %s socket (%s, %s)\n",
                                          poller.item.getSocket() != null ? poller.item.getSocket().getType() : "RAW",
                                                  poller.item.getSocket(),
                                                  poller.item.getRawSocket());
                    }
                    //  Give handler one chance to handle error, then kill
                    //  poller because it'll disrupt the reactor otherwise.
                    if (poller.errors++ > 0) {
                        removePoller(poller.item);
                    }
                }
                else {
                    poller.errors = 0; //  A non-error happened
                }

                if (pollset.getItem(itemNbr).readyOps() > 0) {
                    if (verbose) {
                        System.out.printf(
                                          "I: zloop: call %s socket handler (%s, %s)\n",
                                          poller.item.getSocket() != null ? poller.item.getSocket().getType() : "RAW",
                                                  poller.item.getSocket(),
                                                  poller.item.getRawSocket());
                    }
                    rc = poller.handler.handle(this, poller.item, poller.arg);
                    if (rc == -1) {
                        break; //  Poller handler signaled break
                    }
                }
            }

            //  Now handle any timer zombies
            //  This is going to be slow if we have many zombies
            for (Object arg : zombies) {
                it = timers.iterator();
                while (it.hasNext()) {
                    STimer timer = it.next();
                    if (timer.arg == arg) {
                        it.remove();
                    }
                }
            }
            //  Now handle any new timers added inside the loop
            timers.addAll(newTimers);
            newTimers.clear();

            if (rc == -1) {
                break;
            }
        }

        return rc;
    }
64905
function onError (e) {
            switch (e.target.errorCode) {
            case 12:
                console.log('Error - Attempt to open db with a lower version than the ' +
                        'current one.');
                break;
            default:
                console.log('errorCode: ' + e.target.errorCode);
            }

            console.log(e, e.code, e.message);
        }
1332098
def _defaultErrorHandler(varBinds, **context):
        """"""
        errors = context.get('errors')

        if errors:
            err = errors[-1]
            raise err['error']
669215
def handle_error(err, halt=True):
        
        print('{}{}{}'.format(c.Style.BRIGHT, c.Fore.RED, err))
        if halt:
            sys.exit(1)
1170953
def _method_error_handler(self, response: Dict[str, Any]):
        
        exp = response.get('MESSAGE')
        code = response.get("CODE")
        ID = exp.get("ID")
        raise abort(code, ID=ID, message=exp.get('MESSAGE'))
248882
function commonErrorHandler(err, req, res, next) { // jshint ignore:line

  debug(err);

  // if we got here without an error, it's a 404 case
  if (!err) {
    err = new NotFoundError();
  }

  // here we've got an error, it could be a different one than
  // the one we've constructed, so provide defaults to be safe
  err.message = err.message || 'Internal Server Error';

  res
    .status(err.code || err.statusCode || 500)
    .type('application/json')
    .send(stringify(err));
}
1310202
def error_handler(self, error):
        
        warnings.warn(
            """
            error_handler is deprecated.
            Use FlaskBuzz.build_error_handler instead
            """,
            warnings.DeprecationWarning,
        )
        return error.jsonify(), error.status_code, error.headers
889153
function onError(err) {
    // jshint validthis: true
    notifier.notify({
        title: err.plugin + ' Error',
        message: err.message
    });
    $.util.log(err.toString());
    $.util.beep();
    if (isWatching) {
        this.emit('end');
    } else {
        process.exit(1);
    }
}
24803
function handleError(call, error) {
  var statusMetadata = new Metadata();
  var status = {
    code: constants.status.UNKNOWN,
    details: 'Unknown Error'
  };
  if (error.hasOwnProperty('message')) {
    status.details = error.message;
  }
  if (error.hasOwnProperty('code') && Number.isInteger(error.code)) {
    status.code = error.code;
    if (error.hasOwnProperty('details')) {
      status.details = error.details;
    }
  }
  if (error.hasOwnProperty('metadata')) {
    statusMetadata = error.metadata;
  }
  status.metadata = statusMetadata._getCoreRepresentation();
  var error_batch = {};
  if (!call.metadataSent) {
    error_batch[grpc.opType.SEND_INITIAL_METADATA] =
        (new Metadata())._getCoreRepresentation();
  }
  error_batch[grpc.opType.SEND_STATUS_FROM_SERVER] = status;
  call.startBatch(error_batch, function(){});
}
118654
function Internal(message, code_id) {
    Error.call(this);
    this.message = message || "internal error";
    this.code_id = code_id || null;
    this.statusCode = 500;
}
959763
function handleError(state, message, ex) {
  logError(message + ' (In: ' + state.stack.join(' > ') + ')');
  if (ex) {
    logError(ex);
  }
}
23495
function onError (error) {
  switch (error.code) {
    case 'EACCES':
      throw new InternalServerError(error, 'Port require elevated privileges')
    case 'EADDRINUSE':
      throw new InternalServerError(error, 'Port is already in use')
    default:
      throw new InternalServerError(error, error.message)
  }
}
1215059
function handler ( err, data ){
      if ( callback != null ){
        callback.apply( b9, arguments );
      }
      // only emit events when there is no error
      if ( err == null ){
        b9.emit.call( b9, method, data );
      }
    }
207044
static function set_error_display( $handler ){
		if( ! is_callable($handler) ){
			trigger_error( 'Error display handler is not callable ('.var_export($handler,1).')', E_USER_WARNING );
			return false;
		}
		PLUGError::$displayfunc = $handler;
		return true;
	}
1121101
def error_handler(task):
    """"""
    @wraps(task)
    def wrapper(self, *args, **kwargs):
        try:
            return task(self, *args, **kwargs)
        except Exception as e:
            self.connected = False
            if not self.testing:
                exc_type, exc_obj, exc_tb = sys.exc_info()
                fname = os.path.split(exc_tb.tb_frame.f_code.co_filename)[1]
                error_message = (
                    "[" + str(datetime.now()) + "] Error in task \"" +
                    task.__name__ + "\" (" +
                    fname + "/" + str(exc_tb.tb_lineno) +
                    ")" + e.message
                )
                self.logger.error("%s: RPC instruction failed" % error_message)
    return wrapper
458214
function handleEnoentError(opts, err) {
  console.log(chalk.red(
    '\nError: ' + err.name + '. "' + err.path + '" does not exist.\n'
  ));
}
568294
def handle_error(self, exc=None):
    """"""
    if exc:
      NailgunProtocol.send_stderr(self.request, traceback.format_exc())
    failure_code = 1
    NailgunProtocol.send_exit_with_code(self.request, failure_code)