private void renderResponse(Request request, @Nullable Response response, String stdOut) {
    //myConsoleView.print("\n-------------------evaluation " + response.getUid() + "------------------------", ConsoleViewContentType.NORMAL_OUTPUT);
    if (response != null) {
      final List<Event> events = response.getEvents();
      if (events != null) {
        if (request.getCommand() == Request.Command.DROP_STATE) {
          int droppedCount = 0;
          for (Event event : events) {
            final CodeSnippet.Status prevStatus = event.getPreviousStatus();
            final CodeSnippet.Status status = event.getStatus();
            if (event.getSnippet() != null && prevStatus != status && status == CodeSnippet.Status.DROPPED) {
              droppedCount++;
            }
          }
          JShellDiagnostic.notifyInfo(JavaCompilerBundle.message("jshell.dropped.x.code.snippets", droppedCount), myProject);
        }
        else {
          for (Event event : events) {
            if (event.getCauseSnippet() == null) {
              final String exception = event.getExceptionText();
              if (!StringUtil.isEmptyOrSpaces(exception)) {
                myConsoleView.print("\n" + exception, ConsoleViewContentType.SYSTEM_OUTPUT);
              }
              final String diagnostic = event.getDiagnostic();
              if (!StringUtil.isEmptyOrSpaces(diagnostic)) {
                myConsoleView.print("\n" + diagnostic, ConsoleViewContentType.SYSTEM_OUTPUT);
              }

              final String descr = getEventDescription(event);
              if (!StringUtil.isEmptyOrSpaces(descr)) {
                myConsoleView.print("\n" + descr, ConsoleViewContentType.SYSTEM_OUTPUT);
              }
              final CodeSnippet snippet = event.getSnippet();
              final String value = snippet != null && !snippet.getSubKind().hasValue()? null : event.getValue();
              if (value != null) {
                myConsoleView.print(" = " + (value.isEmpty()? "\"\"" : value), ConsoleViewContentType.NORMAL_OUTPUT);
              }
            }
          }
        }
      }
    }

    if (!StringUtil.isEmpty(stdOut)) {
      //myConsoleView.print("\n-----evaluation output-----\n", ConsoleViewContentType.NORMAL_OUTPUT);
      myConsoleView.print("\n", ConsoleViewContentType.NORMAL_OUTPUT);
      // delegate unparsed text directly to console
      if (!"\n".equals(stdOut) /*hack to ignore possible empty line before 'message-begin' merker*/) {
        myConsoleView.print(stdOut, ConsoleViewContentType.NORMAL_OUTPUT);
      }
    }
  }
private void renderResponse(Request request, @Nullable Response response, String stdOut)