void () { LOG.debug("Refreshing SDK roots and packages cache"); final Application application = ApplicationManager.getApplication(); application.invokeLater(() -> { final Sdk sdk = getSdk(); application.runWriteAction(() -> { final VirtualFile[] files = sdk.getRootProvider().getFiles(OrderRootType.CLASSES); VfsUtil.markDirtyAndRefresh(true, true, true, files); }); PythonSdkType.getInstance().setupSdkPaths(sdk); }); }