Called when a resource fails and will not be retried.
357316
def resource_failed(resource, action, exception)
      expecting_exception(exception) do
        description = Chef::Formatters::ErrorMapper.resource_failed(resource, action, exception)
        display_error(description)
      end
    end
1067190
def on_failure(self, exc, task_id, args, kwargs, einfo):
        
        key = self._get_cache_key(args, kwargs)
        _, penalty = cache.get(key, (0, 0))
        if penalty < self.MAX_PENALTY:
            penalty += 1

        logger.debug('The task %s is penalized and will be executed on %d run.' % (self.name, penalty))
        cache.set(key, (penalty, penalty), self.CACHE_LIFETIME)
        return super(PenalizedBackgroundTask, self).on_failure(exc, task_id, args, kwargs, einfo)
445721
def dispatch_failed(self, context):
        """"""
        traceback.print_exception(
            context.exc_type, context.exc_value, context.traceback)
        raise SystemExit(1)
1187628
private void handleReopenForStorageException(final StorageException exs) throws StorageException {
    reopens++;
    if (reopens > maxReopens) {
      throw new StorageException(
          exs.getCode(),
          "All "
              + maxReopens
              + " reopens failed. Waited a total of "
              + totalWaitTime
              + " ms between attempts",
          exs);
    }
    sleepForAttempt(reopens);
  }
923278
def failure(path, downloader):
    """"""
    base = os.path.basename(path)
    if sys.stdin.isatty():
        print('INFO [{}]: Failed to download {!r}'.format(downloader, base))
    else:
        notify_failure(base, downloader)
123519
private void tryUnlock(CmsResource resource) {

        try {
            m_cms.unlockResource(resource);
        } catch (CmsException e) {
            // usually not a problem
            LOG.debug("failed to unlock " + resource.getRootPath(), e);
        }

    }
184643
def trigger_failure(data=nil)
      event.success = false
      event.data = data
      event.trigger
    end
539469
function onFailure(err) {
          onTimelyResponse(spec.code);

          logError(`Server call for ${spec.code} failed: ${err}. Continuing without bids.`);
          onResponse();
        }
44734
public function failure($service)
    {
        try {
            if ($this->strategy->recordFailure($service) === self::STATUS_TRIPPED) {
                $this->notify(self::EVENT_TRIPPED, $service, '');
            }
        } catch (StorageException $e) {
            $this->notify(self::EVENT_STORAGE_ERROR, $service, 'failed to record failure : ' . $e->getMessage());
        }
    }
944381
def _fail(self, request_id, failure, duration):
        """"""
        self.listeners.publish_command_failure(
            duration, failure, self.name,
            request_id, self.sock_info.address, self.op_id)
1331499
def on_failure(self, exc, task_id, args, kwargs, einfo):
        """"""
        super().on_failure(exc, task_id, args, kwargs, einfo)
        if isinstance(exc, OperationRunDoesNotExist):
            return
        self._operation_run.on_failure()
1348485
public static void ensureNotError(ObjectMapper mapper, JsonNode resourceNode) {
		if (resourceNode != null && resourceNode.hasNonNull(JSONAPISpecConstants.ERRORS)) {
			try {
				throw new ResourceParseException(ErrorUtils.parseError(mapper, resourceNode, Errors.class));
			} catch (JsonProcessingException e) {
				throw new RuntimeException(e);
			}
		}
	}
553308
public function onFailure()
    {
        if ($this->onConnected) {
            $this->onConnected->executeAll($this);
            $this->onConnected = null;
        }
    }
92216
def _on_error(self, exc):
        """"""
        # restart the read scan from AFTER the last successfully read row
        retry_request = self.request
        if self.last_scanned_row_key:
            retry_request = self._create_retry_request()

        self.response_iterator = self.read_method(retry_request)
754427
def on_failure(self, exc, task_id, args, kwargs, einfo):
        
        if not FailedTask.objects.filter(task_id=task_id, datetime_resolved=None).exists():
            FailedTask.objects.create(
                task_name=_truncate_to_field(FailedTask, 'task_name', self.name),
                task_id=task_id,  # Fixed length UUID: No need to truncate
                args=args,
                kwargs=kwargs,
                exc=_truncate_to_field(FailedTask, 'exc', repr(exc)),
            )
        super(PersistOnFailureTask, self).on_failure(exc, task_id, args, kwargs, einfo)
1133744
public void onFailure(Throwable t) {

        if ((t instanceof StatusCodeException) && (((StatusCodeException)t).getStatusCode() == 0)) {
            // a status code 0 indicates the client aborted the request, most likely when leaving the page, this should be ignored
            return;
        } else if ((t instanceof StatusCodeException) && (((StatusCodeException)t).getStatusCode() == 500)) {
            // a server error 500 most likely indicates an expired session and there for insufficient user rights to access any GWT service
            CmsErrorDialog dialog = new CmsErrorDialog(Messages.get().key(Messages.GUI_SESSION_EXPIRED_0), null);
            dialog.center();
        } else {
            CmsErrorDialog.handleException(t);
        }
        // remove the overlay
        stop(false);
    }
801958
public function fail($exception)
    {
        $this->resqueInstance->events->trigger('onFailure', [
            'exception' => $exception,
            'job' => $this
        ]);

        if(isset($this->status)) {
            $this->status->update(ResqueJobStatus::STATUS_FAILED);
        }

        $this->resqueInstance->stats->incr('failed');
        $this->resqueInstance->stats->incr('failed:' . $this->worker);
        if ($this->resqueInstance->backend->recreateFailedJobs) {
            $this->recreate();
        }
    }