void (@NotNull Project project, @NotNull VirtualFile baseDir, @NotNull Ref<Module> moduleRef, boolean isProjectCreatedWithWizard) { VirtualFile setupPy = baseDir.findChild(SETUP_PY); if (setupPy == null) { return; } CharSequence content = LoadTextUtil.loadText(setupPy); PsiElement setupPyFile = PsiFileFactory.getInstance(project).createFileFromText(SETUP_PY, PythonFileType.INSTANCE, content.toString()); final SetupCallVisitor visitor = new SetupCallVisitor(); setupPyFile.accept(visitor); String dir = visitor.getRootPackageDir(); if (dir != null) { VirtualFile rootPackageVFile = baseDir.findFileByRelativePath(dir); addSourceRoot(project, baseDir, rootPackageVFile, true); } }