protected void addTracebackFilter(
     Project project, ConsoleView consoleView, ProcessHandler processHandler) {
   if (PySdkUtil.isRemote(myConfig.getSdk())) {
     assert processHandler instanceof RemoteProcessControl;
     consoleView.addMessageFilter(
         new PyRemoteTracebackFilter(
             project, myConfig.getWorkingDirectory(), (RemoteProcessControl) processHandler));
   } else {
     consoleView.addMessageFilter(
         new PythonTracebackFilter(project, myConfig.getWorkingDirectorySafe()));
   }
   consoleView.addMessageFilter(
       createUrlFilter(processHandler)); // Url filter is always nice to have
 }
  @NotNull
  protected ConsoleView createAndAttachConsole(
      Project project, ProcessHandler processHandler, Executor executor) throws ExecutionException {
    final ConsoleView consoleView = createConsoleBuilder(project).getConsole();
    consoleView.addMessageFilter(createUrlFilter(processHandler));

    addTracebackFilter(project, consoleView, processHandler);

    consoleView.attachToProcess(processHandler);
    return consoleView;
  }
 public void addMessageFilter(final Filter filter) {
   myConsole.addMessageFilter(filter);
 }