void (@NotNull ExternalSystemTaskId id, @NotNull Exception e) { if (progressListener != null) { var eventTime = System.currentTimeMillis(); var eventMessage = BuildBundle.message("build.status.failed"); var title = executionName + " " + BuildBundle.message("build.status.failed"); var externalSystemId = id.getProjectSystemId(); var externalProjectPath = mySettings.getExternalProjectPath(); var dataContext = BuildConsoleUtils.getDataContext(id, progressListener); var eventResult = createFailureResult(title, e, externalSystemId, myProject, externalProjectPath, dataContext); eventDispatcher.onEvent(id, new FinishBuildEventImpl(id, null, eventTime, eventMessage, eventResult)); } processHandler.notifyProcessTerminated(1); }