@Override
  public void computeStackFrames(int firstFrameIndex, XStackFrameContainer container) {
    if (myThreadInfo.getState() != PyThreadInfo.State.SUSPENDED) {
      container.errorOccurred(PyBundle.message("debugger.stack.frames.not.available.in.non.suspended.state"));
      return;
    }

    ApplicationManager.getApplication().executeOnPooledThread(() -> {
      List<PyStackFrameInfo> frames = myThreadInfo.getFrames();
      if (frames != null && firstFrameIndex <= frames.size() && !container.isObsolete()) {
        List<PyStackFrame> xFrames = new LinkedList<>();
        for (int i = firstFrameIndex; i < frames.size() && !container.isObsolete(); i++) {
          xFrames.add(convert(myDebugProcess, frames.get(i)));
        }
        container.addStackFrames(xFrames, true);
      }
      else {
        container.addStackFrames(Collections.emptyList(), true);
      }
    });
  }
@Override
  public void computeStackFrames(int firstFrameIndex, XStackFrameContainer container)