Promise<Object> (@NotNull PlaybackContext context) { AsyncPromise<Object> promise = new AsyncPromise<>(); AppExecutorUtil.getAppExecutorService().execute(() -> { try { computePromise(context.getProject()); promise.setResult("completed"); } catch (Throwable t) { promise.setError(t); } }); return promise; }