public boolean isEmpty(@NotNull ConsoleCommunication consoleComm) {
    if (consoleComm instanceof PydevConsoleCommunication) {
      if (((PydevConsoleCommunication)consoleComm).isCommunicationClosed()) {
        return true;
      }
    }
    var queue = getQueue(consoleComm);
    if (queue == null) return true;
    return queue.isEmpty();
  }
public boolean isEmpty(@NotNull ConsoleCommunication consoleComm)