From 9514b1d4616fcfdb1d4446ba2ef40bba8a5471f9 Mon Sep 17 00:00:00 2001 From: Yuriy Artamonov Date: Mon, 22 Dec 2025 12:12:38 +0100 Subject: [PATCH] [platform] IJPL-224518 Cleanup private modifier usages with extensions/services in intellij.python.* GitOrigin-RevId: 8a3b9d6763dbb00e30c9266ca1decc9803ef6304 --- .../ide/impl/PyCharmCodeVisionSettingsDefaults.kt | 2 +- .../ide/impl/PyCharmCorePluginConfigurator.kt | 2 +- .../impl/PyCharmPythonIdeLanguageCustomization.kt | 2 +- .../PyRequirementsTxtOrSetupPySdkConfiguration.kt | 2 +- .../ide/impl/configuration/PySdkStatusBar.kt | 4 ++-- .../ide/impl/configuration/PyUvSdkConfiguration.kt | 2 +- .../ide/impl/configuration/PyVenvSdkConfiguration.kt | 2 +- .../impl/miscProject/impl/PyNewMiscScriptAction.kt | 2 +- .../impl/newProjectWizard/PyCharmNewProjectAction.kt | 2 +- .../ide/impl/newProjectWizard/welcome/PyWelcome.kt | 2 +- .../PyCharmWelcomeScreenProjectProvider.kt | 2 +- .../community/helpersLocator/PythonHelpersLocator.kt | 2 +- .../intellij/python/ml/features/imports/mlModel.kt | 2 +- .../interpreters/src/impl/InterpreterServiceImpl.kt | 2 +- .../impl/run/PyPluginCommonFragmentsBuilder.kt | 2 +- .../community/plugin/java/PythonNewProjectWizard.kt | 2 +- .../src/com/intellij/python/copyright/PyCopyright.kt | 2 +- .../intellij/python/grazie/PythonProblemFilter.kt | 2 +- .../hatch/sdk/evolution/HatchSelectSdkProvider.kt | 2 +- .../evolution/tool/pip/ui/VenvSelectSdkProvider.kt | 2 +- .../sdk/ui/evolution/ui/EvoPySdkStatusBarWidget.kt | 2 +- .../python/sdk/ui/evolution/ui/autoconfiguration.kt | 4 ++-- .../impl/providers/AsdfSystemProvider.kt | 2 +- .../impl/providers/BrewSystemPythonProvider.kt | 2 +- .../impl/providers/MacSystemPythonProvider.kt | 2 +- .../impl/providers/PyenvSystemPythonProvider.kt | 2 +- .../impl/providers/UnixSystemPythonProvider.kt | 2 +- python/src/com/jetbrains/python/PyIdIndexer.kt | 2 +- .../actions/PyTypeAnnotationsFoldingActions.kt | 4 ++-- .../conda/sdk/evolution/CondaSelectSdkProvider.kt | 2 +- .../configuration/PythonInterpreterMasterDetails.kt | 2 +- .../packaging/management/PythonPackagesUpdater.kt | 2 +- .../poetry/PoetryPyProjectTomlPostStartupActivity.kt | 2 +- .../PoetryPackageRequirementsTreeExtractor.kt | 2 +- .../PoetryPythonPackageRequiresExtractor.kt | 2 +- .../poetry/sdk/evolution/PoetrySelectSdkProvider.kt | 4 ++-- .../python/run/PythonLockedRunConfiguration.kt | 12 ++++++------ .../jetbrains/python/sdk/AddInterpreterActions.kt | 2 +- .../python/sdk/evolution/advancedActions.kt | 2 +- .../jetbrains/python/sdk/uv/run/UvRunToolProvider.kt | 2 +- .../packaging/UvPackageRequirementsTreeExtractor.kt | 2 +- .../uv/packaging/UvPythonPackageRequiresExtractor.kt | 2 +- .../python/uv/sdk/evolution/UvSelectSdkProvider.kt | 2 +- 43 files changed, 52 insertions(+), 52 deletions(-) diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmCodeVisionSettingsDefaults.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmCodeVisionSettingsDefaults.kt index a8d681ec16c0..ff42d61ece03 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmCodeVisionSettingsDefaults.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmCodeVisionSettingsDefaults.kt @@ -4,6 +4,6 @@ package com.intellij.pycharm.community.ide.impl import com.intellij.codeInsight.codeVision.CodeVisionAnchorKind import com.intellij.codeInsight.codeVision.settings.CodeVisionSettingsDefaults -private class PyCharmCodeVisionSettingsDefaults : CodeVisionSettingsDefaults { +internal class PyCharmCodeVisionSettingsDefaults : CodeVisionSettingsDefaults { override val defaultPosition: CodeVisionAnchorKind get() = CodeVisionAnchorKind.Right } \ No newline at end of file diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmCorePluginConfigurator.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmCorePluginConfigurator.kt index 4c94b7c74089..ef8f9b5cb6b4 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmCorePluginConfigurator.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmCorePluginConfigurator.kt @@ -32,7 +32,7 @@ import kotlin.time.Duration.Companion.milliseconds * This class is called **only in PyCharm**. * It does not work in plugin */ -private class PyCharmCorePluginConfigurator : ApplicationInitializedListener { +internal class PyCharmCorePluginConfigurator : ApplicationInitializedListener { init { if (ApplicationManager.getApplication().isHeadlessEnvironment()) { throw ExtensionNotApplicableException.create() diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmPythonIdeLanguageCustomization.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmPythonIdeLanguageCustomization.kt index 2accf83925d1..f0690f89d6e9 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmPythonIdeLanguageCustomization.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/PyCharmPythonIdeLanguageCustomization.kt @@ -3,4 +3,4 @@ package com.intellij.pycharm.community.ide.impl import com.jetbrains.python.PythonIdeLanguageCustomization -private class PyCharmPythonIdeLanguageCustomization : PythonIdeLanguageCustomization() \ No newline at end of file +internal class PyCharmPythonIdeLanguageCustomization : PythonIdeLanguageCustomization() \ No newline at end of file diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyRequirementsTxtOrSetupPySdkConfiguration.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyRequirementsTxtOrSetupPySdkConfiguration.kt index eccbf1663b30..989c1dec0331 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyRequirementsTxtOrSetupPySdkConfiguration.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyRequirementsTxtOrSetupPySdkConfiguration.kt @@ -46,7 +46,7 @@ private val LOGGER = fileLogger() internal val PY_REQ_TOOL_ID = ToolId("requirements.txt") -private class PyRequirementsTxtOrSetupPySdkConfiguration : PyProjectSdkConfigurationExtension { +internal class PyRequirementsTxtOrSetupPySdkConfiguration : PyProjectSdkConfigurationExtension { override val toolId: ToolId = PY_REQ_TOOL_ID // This is nonsense, but will be dropped soon diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PySdkStatusBar.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PySdkStatusBar.kt index b8480fedd9dc..e2526f178b91 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PySdkStatusBar.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PySdkStatusBar.kt @@ -33,7 +33,7 @@ private const val ID: String = "pythonInterpreterWidget" fun isDataSpellInterpreterWidgetEnabled(): Boolean = PlatformUtils.isDataSpell() && Registry.`is`("dataspell.interpreter.widget") -private class PySdkStatusBarWidgetFactory : StatusBarWidgetFactory { +internal class PySdkStatusBarWidgetFactory : StatusBarWidgetFactory { override fun getId(): String = ID override fun getDisplayName(): String = PyBundle.message("configurable.PyActiveSdkModuleConfigurable.python.interpreter.display.name") @@ -45,7 +45,7 @@ private class PySdkStatusBarWidgetFactory : StatusBarWidgetFactory { override fun createWidget(project: Project, scope: CoroutineScope): StatusBarWidget = PySdkStatusBar(project, scope) } -private class PySwitchSdkAction : DumbAwareAction(PyBundle.message("switch.python.interpreter"), null, null) { +internal class PySwitchSdkAction : DumbAwareAction(PyBundle.message("switch.python.interpreter"), null, null) { override fun update(e: AnActionEvent) { e.presentation.isVisible = e.getData(CommonDataKeys.VIRTUAL_FILE) != null && e.project != null } diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyUvSdkConfiguration.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyUvSdkConfiguration.kt index 5b9d3658c8f6..a98a182cc007 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyUvSdkConfiguration.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyUvSdkConfiguration.kt @@ -32,7 +32,7 @@ import java.nio.file.Path private val logger = fileLogger() -private class PyUvSdkConfiguration : PyProjectTomlConfigurationExtension { +internal class PyUvSdkConfiguration : PyProjectTomlConfigurationExtension { private val existingSdks by lazy { PythonSdkUtil.getAllSdks() } private val context = UserDataHolderBase() diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyVenvSdkConfiguration.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyVenvSdkConfiguration.kt index db4ff06e6f84..82a38e4dc752 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyVenvSdkConfiguration.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/configuration/PyVenvSdkConfiguration.kt @@ -20,7 +20,7 @@ import com.jetbrains.python.sdk.legacy.PythonSdkUtil import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext -private class PyVenvSdkConfiguration : PyProjectSdkConfigurationExtension { +internal class PyVenvSdkConfiguration : PyProjectSdkConfigurationExtension { private val existingSdks by lazy { PythonSdkUtil.getAllSdks() } private val context = UserDataHolderBase() diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/miscProject/impl/PyNewMiscScriptAction.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/miscProject/impl/PyNewMiscScriptAction.kt index c09b6ab88b19..b20f3b09a782 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/miscProject/impl/PyNewMiscScriptAction.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/miscProject/impl/PyNewMiscScriptAction.kt @@ -1,4 +1,4 @@ // Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. package com.intellij.pycharm.community.ide.impl.miscProject.impl -private class PyNewMiscScriptAction : PyMiscFileAction(MiscScriptFileType) +internal class PyNewMiscScriptAction : PyMiscFileAction(MiscScriptFileType) diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/newProjectWizard/PyCharmNewProjectAction.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/newProjectWizard/PyCharmNewProjectAction.kt index 7c173c59ad93..0b627be6f67e 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/newProjectWizard/PyCharmNewProjectAction.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/newProjectWizard/PyCharmNewProjectAction.kt @@ -14,7 +14,7 @@ import kotlinx.coroutines.withContext /** * New project wizard entry point */ -private class PyCharmNewProjectAction : DumbAwareAction() { +internal class PyCharmNewProjectAction : DumbAwareAction() { override fun actionPerformed(e: AnActionEvent) { e.coroutineScope.launch { runCatching { diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/newProjectWizard/welcome/PyWelcome.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/newProjectWizard/welcome/PyWelcome.kt index 3b84cb7e51d9..65e6997de9d1 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/newProjectWizard/welcome/PyWelcome.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/newProjectWizard/welcome/PyWelcome.kt @@ -53,7 +53,7 @@ import org.jetbrains.annotations.CalledInAny import org.jetbrains.concurrency.CancellablePromise import java.util.concurrent.Callable -private class PyWelcomeConfigurator : DirectoryProjectConfigurator { +internal class PyWelcomeConfigurator : DirectoryProjectConfigurator { override val isEdtRequired: Boolean get() = false diff --git a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/welcomeScreen/PyCharmWelcomeScreenProjectProvider.kt b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/welcomeScreen/PyCharmWelcomeScreenProjectProvider.kt index ab72064cf656..4ac01350b989 100644 --- a/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/welcomeScreen/PyCharmWelcomeScreenProjectProvider.kt +++ b/python/ide/impl/src/com/intellij/pycharm/community/ide/impl/welcomeScreen/PyCharmWelcomeScreenProjectProvider.kt @@ -16,7 +16,7 @@ import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext import java.nio.file.Path -private class PyCharmWelcomeScreenProjectProvider : WelcomeScreenProjectProvider() { +internal class PyCharmWelcomeScreenProjectProvider : WelcomeScreenProjectProvider() { override fun getWelcomeScreenProjectName(): String = MISC_PROJECT_WITH_WELCOME_NAME override fun getWelcomeScreenProjectPath(): Path = miscProjectDefaultPath diff --git a/python/impl.helperLocator/src/com/intellij/python/community/helpersLocator/PythonHelpersLocator.kt b/python/impl.helperLocator/src/com/intellij/python/community/helpersLocator/PythonHelpersLocator.kt index ae39ad647323..5da601e03731 100644 --- a/python/impl.helperLocator/src/com/intellij/python/community/helpersLocator/PythonHelpersLocator.kt +++ b/python/impl.helperLocator/src/com/intellij/python/community/helpersLocator/PythonHelpersLocator.kt @@ -167,4 +167,4 @@ interface PythonHelpersLocator { } } -private class PythonHelpersLocatorDefault : PythonHelpersLocator +internal class PythonHelpersLocatorDefault : PythonHelpersLocator diff --git a/python/intellij.python.ml.features/src/com/intellij/python/ml/features/imports/mlModel.kt b/python/intellij.python.ml.features/src/com/intellij/python/ml/features/imports/mlModel.kt index 6a96c26abbf0..0b6b10cc7bab 100644 --- a/python/intellij.python.ml.features/src/com/intellij/python/ml/features/imports/mlModel.kt +++ b/python/intellij.python.ml.features/src/com/intellij/python/ml/features/imports/mlModel.kt @@ -52,7 +52,7 @@ internal class ImportsRankingModelService { } } -private class QuickfixRankingModelLoading : ProjectActivity { +internal class QuickfixRankingModelLoading : ProjectActivity { override suspend fun execute(project: Project) { if (!service().shouldLoadModel) return ImportsRankingModelService.getInstance() diff --git a/python/interpreters/src/impl/InterpreterServiceImpl.kt b/python/interpreters/src/impl/InterpreterServiceImpl.kt index ba3e817be404..0c7680271f14 100644 --- a/python/interpreters/src/impl/InterpreterServiceImpl.kt +++ b/python/interpreters/src/impl/InterpreterServiceImpl.kt @@ -98,7 +98,7 @@ private suspend fun createInterpreter(provider: InterpreterPr } } -private class VanillaInterpreterProvider : InterpreterProvider { +internal class VanillaInterpreterProvider : InterpreterProvider { override val ui: PyToolUIInfo? = null override val flavorDataClass: Class = PyFlavorData.Empty::class.java diff --git a/python/pluginCore/impl/src/com/intellij/python/community/plugin/impl/run/PyPluginCommonFragmentsBuilder.kt b/python/pluginCore/impl/src/com/intellij/python/community/plugin/impl/run/PyPluginCommonFragmentsBuilder.kt index 36f0d8673a83..70d3a8c72cd0 100644 --- a/python/pluginCore/impl/src/com/intellij/python/community/plugin/impl/run/PyPluginCommonFragmentsBuilder.kt +++ b/python/pluginCore/impl/src/com/intellij/python/community/plugin/impl/run/PyPluginCommonFragmentsBuilder.kt @@ -11,7 +11,7 @@ import com.jetbrains.python.run.configuration.PyPathMappingsEditorFragment import javax.swing.JPanel import kotlin.io.path.Path -private class PyPluginCommonFragmentsBuilder: PyCommonFragmentsBuilder() { +internal class PyPluginCommonFragmentsBuilder: PyCommonFragmentsBuilder() { override fun > createEnvironmentFragments(fragments: MutableList>, config: T) { val sdkFragment: SettingsEditorFragment = PyPluginSdkFragment() diff --git a/python/pluginJava/src/com/intellij/python/community/plugin/java/PythonNewProjectWizard.kt b/python/pluginJava/src/com/intellij/python/community/plugin/java/PythonNewProjectWizard.kt index 361a4567b684..3c49932afe03 100644 --- a/python/pluginJava/src/com/intellij/python/community/plugin/java/PythonNewProjectWizard.kt +++ b/python/pluginJava/src/com/intellij/python/community/plugin/java/PythonNewProjectWizard.kt @@ -13,7 +13,7 @@ import javax.swing.Icon * * It suggests creating a new Python virtual environment for your new project to follow Python best practices. */ -private class PythonNewProjectWizard : LanguageGeneratorNewProjectWizard { +internal class PythonNewProjectWizard : LanguageGeneratorNewProjectWizard { override val name: String get() = NewProjectWizardConstants.Language.PYTHON diff --git a/python/python-copyright/src/com/intellij/python/copyright/PyCopyright.kt b/python/python-copyright/src/com/intellij/python/copyright/PyCopyright.kt index 5f33b7a5c57e..5965442cd614 100644 --- a/python/python-copyright/src/com/intellij/python/copyright/PyCopyright.kt +++ b/python/python-copyright/src/com/intellij/python/copyright/PyCopyright.kt @@ -17,7 +17,7 @@ import com.maddyhome.idea.copyright.psi.UpdatePsiFileCopyright import java.util.function.Predicate import java.util.regex.Pattern -private class PyUpdateCopyrightsProvider : UpdateCopyrightsProvider() { +internal class PyUpdateCopyrightsProvider : UpdateCopyrightsProvider() { override fun createInstance(project: Project, module: Module?, file: VirtualFile, diff --git a/python/python-grazie/src/com/intellij/python/grazie/PythonProblemFilter.kt b/python/python-grazie/src/com/intellij/python/grazie/PythonProblemFilter.kt index 45956ea6b275..b24ee058d60b 100644 --- a/python/python-grazie/src/com/intellij/python/grazie/PythonProblemFilter.kt +++ b/python/python-grazie/src/com/intellij/python/grazie/PythonProblemFilter.kt @@ -10,7 +10,7 @@ import java.util.regex.Pattern private val PY_DOC_PARAM = Pattern.compile("[a-z0-9_]+\\s*:\\s+\\p{L}+( or \\p{L}+)*") -private class PythonProblemFilter : ProblemFilter() { +internal class PythonProblemFilter : ProblemFilter() { override fun shouldIgnore(problem: TextProblem): Boolean { val domain = problem.text.domain return domain == TextContent.TextDomain.DOCUMENTATION && diff --git a/python/python-hatch/src/com/intellij/python/hatch/sdk/evolution/HatchSelectSdkProvider.kt b/python/python-hatch/src/com/intellij/python/hatch/sdk/evolution/HatchSelectSdkProvider.kt index a8760d3233aa..0f51ca0706df 100644 --- a/python/python-hatch/src/com/intellij/python/hatch/sdk/evolution/HatchSelectSdkProvider.kt +++ b/python/python-hatch/src/com/intellij/python/hatch/sdk/evolution/HatchSelectSdkProvider.kt @@ -18,7 +18,7 @@ import com.intellij.python.sdk.ui.evolution.ui.components.EvoTreeLazyNodeElement import com.intellij.python.sdk.ui.evolution.ui.components.EvoTreeLeafElement import com.intellij.python.sdk.ui.evolution.ui.components.EvoTreeSection -private class HatchSelectSdkProvider : EvoSelectSdkProvider { +internal class HatchSelectSdkProvider : EvoSelectSdkProvider { override fun getTreeElement(evoModuleSdk: EvoModuleSdk): EvoTreeElement = EvoTreeLazyNodeElement("Hatch", PythonHatchIcons.Logo) { val hatchExecutablePath = HatchConfiguration.getOrDetectHatchExecutablePath().getOr { diff --git a/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/tool/pip/ui/VenvSelectSdkProvider.kt b/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/tool/pip/ui/VenvSelectSdkProvider.kt index c92b8a3d0696..e3b21c952faa 100644 --- a/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/tool/pip/ui/VenvSelectSdkProvider.kt +++ b/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/tool/pip/ui/VenvSelectSdkProvider.kt @@ -16,7 +16,7 @@ import com.jetbrains.python.sdk.basePath import java.nio.file.Path import kotlin.collections.plus -private class VenvSelectSdkProvider() : EvoSelectSdkProvider { +internal class VenvSelectSdkProvider() : EvoSelectSdkProvider { override fun getTreeElement(evoModuleSdk: EvoModuleSdk) = EvoTreeLazyNodeElement("pip", PythonSdkUIIcons.Tools.Pip) { val environments = VenvEvoSdkManager.findEnvironments(evoModuleSdk.module).getOr { return@EvoTreeLazyNodeElement it diff --git a/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/ui/EvoPySdkStatusBarWidget.kt b/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/ui/EvoPySdkStatusBarWidget.kt index 13018c042675..919369e40e0e 100644 --- a/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/ui/EvoPySdkStatusBarWidget.kt +++ b/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/ui/EvoPySdkStatusBarWidget.kt @@ -23,7 +23,7 @@ import kotlinx.coroutines.CoroutineScope private const val ID: String = "EvoPySdkStatusBarWidget" -private class PySdkStatusBarWidgetFactory : StatusBarWidgetFactory { +internal class PySdkStatusBarWidgetFactory : StatusBarWidgetFactory { override fun getId(): String = ID override fun getDisplayName(): String = PySdkUiBundle.message("evo.sdk.status.bar.widget.factory.display.name") diff --git a/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/ui/autoconfiguration.kt b/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/ui/autoconfiguration.kt index 5c8b18faee5d..54c7e7d6cae3 100644 --- a/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/ui/autoconfiguration.kt +++ b/python/python-sdk-ui/src/com/intellij/python/sdk/ui/evolution/ui/autoconfiguration.kt @@ -31,7 +31,7 @@ internal val defaultUvAction = object : AnAction( } -private class AutoconfigSelectSdkProvider() : EvoSelectSdkProvider { +internal class AutoconfigSelectSdkProvider() : EvoSelectSdkProvider { override fun getTreeElement(evoModuleSdk: EvoModuleSdk) = EvoTreeLazyNodeElement( text = PySdkUiBundle.message("evo.sdk.status.bar.popup.shortcuts.best.options"), icon = AllIcons.General.Layout @@ -57,7 +57,7 @@ private val ratingIcons = listOf( AllIcons.Ide.Rating1, ) -private class RunConfiguratorAction( +internal class RunConfiguratorAction( intention: String, order: Int, ) : AnAction({ intention }, { intention }, ratingIcons.getOrElse(order, { AllIcons.Ide.Rating1 })) { diff --git a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/AsdfSystemProvider.kt b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/AsdfSystemProvider.kt index ba6b4e5cf6e9..598685e55c4f 100644 --- a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/AsdfSystemProvider.kt +++ b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/AsdfSystemProvider.kt @@ -15,7 +15,7 @@ import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext -private class AsdfSystemPythonProvider : SystemPythonProvider { +internal class AsdfSystemPythonProvider : SystemPythonProvider { private val LOGGER: Logger = Logger.getInstance(AsdfSystemPythonProvider::class.java) override suspend fun findSystemPythons(eelApi: EelApi): PyResult> { diff --git a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/BrewSystemPythonProvider.kt b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/BrewSystemPythonProvider.kt index c37f4320a821..262f8f76217a 100644 --- a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/BrewSystemPythonProvider.kt +++ b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/BrewSystemPythonProvider.kt @@ -14,7 +14,7 @@ import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext -private class BrewSystemPythonProvider : SystemPythonProvider { +internal class BrewSystemPythonProvider : SystemPythonProvider { private val LOGGER: Logger = Logger.getInstance(BrewSystemPythonProvider::class.java) private val binDirectory = Path.of("/opt/homebrew/bin") diff --git a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/MacSystemPythonProvider.kt b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/MacSystemPythonProvider.kt index 47a3911d20f3..5120243aa526 100644 --- a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/MacSystemPythonProvider.kt +++ b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/MacSystemPythonProvider.kt @@ -13,7 +13,7 @@ import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext -private class MacSystemPythonProvider : SystemPythonProvider { +internal class MacSystemPythonProvider : SystemPythonProvider { private val LOGGER: Logger = Logger.getInstance(MacSystemPythonProvider::class.java) private val directories = listOf( diff --git a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/PyenvSystemPythonProvider.kt b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/PyenvSystemPythonProvider.kt index cdfdb66328a1..07a31cd12df2 100644 --- a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/PyenvSystemPythonProvider.kt +++ b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/PyenvSystemPythonProvider.kt @@ -15,7 +15,7 @@ import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext -private class PyenvSystemPythonProvider : SystemPythonProvider { +internal class PyenvSystemPythonProvider : SystemPythonProvider { private val LOGGER: Logger = Logger.getInstance(PyenvSystemPythonProvider::class.java) override suspend fun findSystemPythons(eelApi: EelApi): PyResult> { diff --git a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/UnixSystemPythonProvider.kt b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/UnixSystemPythonProvider.kt index 5b22ddfd81d7..a963f4594899 100644 --- a/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/UnixSystemPythonProvider.kt +++ b/python/services/system-python/src/com/intellij/python/community/services/systemPython/impl/providers/UnixSystemPythonProvider.kt @@ -14,7 +14,7 @@ import kotlinx.coroutines.withContext import java.nio.file.Path -private class UnixSystemPythonProvider : SystemPythonProvider { +internal class UnixSystemPythonProvider : SystemPythonProvider { private val LOGGER: Logger = Logger.getInstance(UnixSystemPythonProvider::class.java) private val directories = listOf( diff --git a/python/src/com/jetbrains/python/PyIdIndexer.kt b/python/src/com/jetbrains/python/PyIdIndexer.kt index 0c402042f32f..2997cb051ce3 100644 --- a/python/src/com/jetbrains/python/PyIdIndexer.kt +++ b/python/src/com/jetbrains/python/PyIdIndexer.kt @@ -6,7 +6,7 @@ import com.intellij.psi.impl.cache.impl.OccurrenceConsumer import com.intellij.psi.impl.cache.impl.id.LexerBasedIdIndexer import com.jetbrains.python.lexer.PythonLexer -private class PyIdIndexer : LexerBasedIdIndexer() { +internal class PyIdIndexer : LexerBasedIdIndexer() { override fun createLexer(consumer: OccurrenceConsumer): Lexer { return createPyIndexingLexer(consumer) } diff --git a/python/src/com/jetbrains/python/actions/PyTypeAnnotationsFoldingActions.kt b/python/src/com/jetbrains/python/actions/PyTypeAnnotationsFoldingActions.kt index bded5b223c27..2696d509d09d 100644 --- a/python/src/com/jetbrains/python/actions/PyTypeAnnotationsFoldingActions.kt +++ b/python/src/com/jetbrains/python/actions/PyTypeAnnotationsFoldingActions.kt @@ -8,9 +8,9 @@ import com.intellij.openapi.editor.Editor import com.intellij.openapi.editor.actionSystem.EditorAction import com.jetbrains.python.PythonFoldingBuilder -private class PyCollapseTypeAnnotationsAction : EditorAction(PyTypeAnnotationsFoldingHandler(false)) +internal class PyCollapseTypeAnnotationsAction : EditorAction(PyTypeAnnotationsFoldingHandler(false)) -private class PyExpandTypeAnnotationsAction : EditorAction(PyTypeAnnotationsFoldingHandler(true)) +internal class PyExpandTypeAnnotationsAction : EditorAction(PyTypeAnnotationsFoldingHandler(true)) internal class PyTypeAnnotationsFoldingHandler(val expand: Boolean) : BaseFoldingHandler() { override fun doExecute(editor: Editor, caret: Caret?, dataContext: DataContext) { diff --git a/python/src/com/jetbrains/python/conda/sdk/evolution/CondaSelectSdkProvider.kt b/python/src/com/jetbrains/python/conda/sdk/evolution/CondaSelectSdkProvider.kt index 1ae6226cb6f8..6617aa86b718 100644 --- a/python/src/com/jetbrains/python/conda/sdk/evolution/CondaSelectSdkProvider.kt +++ b/python/src/com/jetbrains/python/conda/sdk/evolution/CondaSelectSdkProvider.kt @@ -27,7 +27,7 @@ import java.nio.file.Path import kotlin.io.path.exists import kotlin.io.path.name -private class CondaSelectSdkProvider() : EvoSelectSdkProvider { +internal class CondaSelectSdkProvider() : EvoSelectSdkProvider { override fun getTreeElement(evoModuleSdk: EvoModuleSdk) = EvoTreeLazyNodeElement("Conda", PythonIcons.Python.Anaconda) { val condaExecutablePath = findCondaExecutablePath().getOr { return@EvoTreeLazyNodeElement it diff --git a/python/src/com/jetbrains/python/configuration/PythonInterpreterMasterDetails.kt b/python/src/com/jetbrains/python/configuration/PythonInterpreterMasterDetails.kt index 6308815d11b5..3d644b5f180d 100644 --- a/python/src/com/jetbrains/python/configuration/PythonInterpreterMasterDetails.kt +++ b/python/src/com/jetbrains/python/configuration/PythonInterpreterMasterDetails.kt @@ -161,7 +161,7 @@ internal class PythonInterpreterMasterDetails(private val moduleOrProject: Modul /** * Note that implementing [MasterDetailsComponent.ActionGroupWithPreselection] guarantees that the group action will be handled as popup. */ - private class PopupActionGroup(actions: List) : DefaultActionGroup(actions), ActionGroupWithPreselection { + internal class PopupActionGroup(actions: List) : DefaultActionGroup(actions), ActionGroupWithPreselection { override fun getActionGroup(): ActionGroup = this } diff --git a/python/src/com/jetbrains/python/packaging/management/PythonPackagesUpdater.kt b/python/src/com/jetbrains/python/packaging/management/PythonPackagesUpdater.kt index 21b128c1a938..af2049c7d711 100644 --- a/python/src/com/jetbrains/python/packaging/management/PythonPackagesUpdater.kt +++ b/python/src/com/jetbrains/python/packaging/management/PythonPackagesUpdater.kt @@ -14,7 +14,7 @@ import com.jetbrains.python.packaging.pip.PypiPackageCache import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext -private class PythonPackagesUpdater : ProjectActivity { +internal class PythonPackagesUpdater : ProjectActivity { init { if (ApplicationManager.getApplication().isUnitTestMode || Registry.`is`("disable.python.cache.update")) { throw ExtensionNotApplicableException.create() diff --git a/python/src/com/jetbrains/python/poetry/PoetryPyProjectTomlPostStartupActivity.kt b/python/src/com/jetbrains/python/poetry/PoetryPyProjectTomlPostStartupActivity.kt index 73e232b0c3ac..47b9e176befd 100644 --- a/python/src/com/jetbrains/python/poetry/PoetryPyProjectTomlPostStartupActivity.kt +++ b/python/src/com/jetbrains/python/poetry/PoetryPyProjectTomlPostStartupActivity.kt @@ -18,7 +18,7 @@ import kotlinx.coroutines.withContext * This class represents a post-startup activity for PyProjectToml files in a project. * It finds valid python versions in PyProjectToml files and saves them in PyProjectTomlPythonVersionsService. */ -private class PoetryPyProjectTomlPostStartupActivity : ProjectActivity { +internal class PoetryPyProjectTomlPostStartupActivity : ProjectActivity { override suspend fun execute(project: Project) { val modulesRoots = PythonSdkUpdater.getModuleRoots(project) for (module in modulesRoots) { diff --git a/python/src/com/jetbrains/python/poetry/packaging/PoetryPackageRequirementsTreeExtractor.kt b/python/src/com/jetbrains/python/poetry/packaging/PoetryPackageRequirementsTreeExtractor.kt index 1ee8338bbfc5..4f09f1f04c5b 100644 --- a/python/src/com/jetbrains/python/poetry/packaging/PoetryPackageRequirementsTreeExtractor.kt +++ b/python/src/com/jetbrains/python/poetry/packaging/PoetryPackageRequirementsTreeExtractor.kt @@ -27,7 +27,7 @@ internal class PoetryPackageRequirementsTreeExtractor(private val sdk: Sdk) : Py } } -private class PoetryPackageRequirementsTreeExtractorProvider : PythonPackageRequirementsTreeExtractorProvider { +internal class PoetryPackageRequirementsTreeExtractorProvider : PythonPackageRequirementsTreeExtractorProvider { override fun createExtractor(sdk: Sdk): PythonPackageRequirementsTreeExtractor? = if (sdk.isPoetry) PoetryPackageRequirementsTreeExtractor(sdk) else null } \ No newline at end of file diff --git a/python/src/com/jetbrains/python/poetry/packaging/PoetryPythonPackageRequiresExtractor.kt b/python/src/com/jetbrains/python/poetry/packaging/PoetryPythonPackageRequiresExtractor.kt index 3ce0544625ce..e5598cc92264 100644 --- a/python/src/com/jetbrains/python/poetry/packaging/PoetryPythonPackageRequiresExtractor.kt +++ b/python/src/com/jetbrains/python/poetry/packaging/PoetryPythonPackageRequiresExtractor.kt @@ -51,7 +51,7 @@ internal class PoetryPackageRequirementExtractor(private val sdk: Sdk) : PythonP } } -private class PoetryRequiresExtractorProvider: PythonPackageRequiresExtractorProvider { +internal class PoetryRequiresExtractorProvider: PythonPackageRequiresExtractorProvider { override fun createExtractor(sdk: Sdk): PythonPackageRequirementExtractor? { if (!sdk.isPoetry) return null return PoetryPackageRequirementExtractor(sdk) diff --git a/python/src/com/jetbrains/python/poetry/sdk/evolution/PoetrySelectSdkProvider.kt b/python/src/com/jetbrains/python/poetry/sdk/evolution/PoetrySelectSdkProvider.kt index fc302b4219b0..2457a6134642 100644 --- a/python/src/com/jetbrains/python/poetry/sdk/evolution/PoetrySelectSdkProvider.kt +++ b/python/src/com/jetbrains/python/poetry/sdk/evolution/PoetrySelectSdkProvider.kt @@ -31,7 +31,7 @@ import java.nio.file.Path import kotlin.io.path.Path import kotlin.io.path.name -private class PoetrySelectSdkProvider() : EvoSelectSdkProvider { +internal class PoetrySelectSdkProvider() : EvoSelectSdkProvider { override fun getTreeElement(evoModuleSdk: EvoModuleSdk): EvoTreeElement = EvoTreeLazyNodeElement("Poetry", PythonIcons.Python.Origami) { getPoetryExecutable() ?:PyResult.localizedError(PyBundle.message("python.sdk.poetry.execution.exception.no.poetry.message")) @@ -84,7 +84,7 @@ private class PoetrySelectSdkProvider() : EvoSelectSdkProvider { } } -private class SelectPoetryEnvAction( +internal class SelectPoetryEnvAction( title: String, installedVersion: Version?, diff --git a/python/src/com/jetbrains/python/run/PythonLockedRunConfiguration.kt b/python/src/com/jetbrains/python/run/PythonLockedRunConfiguration.kt index 9f9bb40e7bd6..252fb9bd5902 100644 --- a/python/src/com/jetbrains/python/run/PythonLockedRunConfiguration.kt +++ b/python/src/com/jetbrains/python/run/PythonLockedRunConfiguration.kt @@ -124,7 +124,7 @@ private class PythonLockedRunConfigurationFactory(type: ConfigurationType) } } -private open class PythonLockedRunConfigurationTypeBase(val theId: String, @Nls val name: String) +internal open class PythonLockedRunConfigurationTypeBase(val theId: String, @Nls val name: String) : ConfigurationType { private val factory: ConfigurationFactory = PythonLockedRunConfigurationFactory(this) @@ -167,11 +167,11 @@ private open class PythonLockedRunConfigurationTypeBase(val theId: String, @Nls } -private class DjangoServerLockedRunConfigurationType : PythonLockedRunConfigurationTypeBase("Python.DjangoServer", PyBundle.message("python.run.configuration.django.name")) -private class FlaskServerLockedRunConfigurationType : PythonLockedRunConfigurationTypeBase("Python.FlaskServer", PyBundle.message("flask.name")) -private class DbtRunLockedConfigurationType : PythonLockedRunConfigurationTypeBase("DbtRunConfiguration", PyBundle.message("python.run.configuration.dbt.name")) -private class FastAPILockedRunConfigurationType : PythonLockedRunConfigurationTypeBase("Python.FastAPI", PyBundle.message("python.run.configuration.fastapi.name")) +internal class DjangoServerLockedRunConfigurationType : PythonLockedRunConfigurationTypeBase("Python.DjangoServer", PyBundle.message("python.run.configuration.django.name")) +internal class FlaskServerLockedRunConfigurationType : PythonLockedRunConfigurationTypeBase("Python.FlaskServer", PyBundle.message("flask.name")) +internal class DbtRunLockedConfigurationType : PythonLockedRunConfigurationTypeBase("DbtRunConfiguration", PyBundle.message("python.run.configuration.dbt.name")) +internal class FastAPILockedRunConfigurationType : PythonLockedRunConfigurationTypeBase("Python.FastAPI", PyBundle.message("python.run.configuration.fastapi.name")) -private class DjangoFacetIgnorer : FacetIgnorer { +internal class DjangoFacetIgnorer : FacetIgnorer { override fun isIgnored(facet: InvalidFacet): Boolean = facet.name == "Django" } \ No newline at end of file diff --git a/python/src/com/jetbrains/python/sdk/AddInterpreterActions.kt b/python/src/com/jetbrains/python/sdk/AddInterpreterActions.kt index b16e9ab021eb..ff7ebe063d72 100644 --- a/python/src/com/jetbrains/python/sdk/AddInterpreterActions.kt +++ b/python/src/com/jetbrains/python/sdk/AddInterpreterActions.kt @@ -115,7 +115,7 @@ internal class AddLocalInterpreterAction( fun addLocalInterpreter(moduleOrProject: ModuleOrProject, onSdkCreated: (Sdk) -> Unit): Unit = createAddLocalInterpreterAction(moduleOrProject, onSdkCreated).createDialog().show() -private class AddInterpreterOnTargetAction( +internal class AddInterpreterOnTargetAction( private val project: Project, private val targetType: TargetEnvironmentType<*>, private val onSdkCreated: (Sdk) -> Unit, diff --git a/python/src/com/jetbrains/python/sdk/evolution/advancedActions.kt b/python/src/com/jetbrains/python/sdk/evolution/advancedActions.kt index f74874cbc84e..22e06d6f2ad6 100644 --- a/python/src/com/jetbrains/python/sdk/evolution/advancedActions.kt +++ b/python/src/com/jetbrains/python/sdk/evolution/advancedActions.kt @@ -15,7 +15,7 @@ import com.jetbrains.python.sdk.pythonSdk import com.jetbrains.python.sdk.switchToSdk -private class AdvancedSelectSdkProvider() : EvoSelectSdkProvider { +internal class AdvancedSelectSdkProvider() : EvoSelectSdkProvider { override fun getTreeElement(evoModuleSdk: EvoModuleSdk) = EvoTreeLazyNodeElement( text = PySdkUiBundle.message("evo.sdk.status.bar.popup.select.advanced"), icon = AllIcons.Toolwindows.ToolWindowInternal diff --git a/python/src/com/jetbrains/python/sdk/uv/run/UvRunToolProvider.kt b/python/src/com/jetbrains/python/sdk/uv/run/UvRunToolProvider.kt index 5541326260a4..2ac79fcad538 100644 --- a/python/src/com/jetbrains/python/sdk/uv/run/UvRunToolProvider.kt +++ b/python/src/com/jetbrains/python/sdk/uv/run/UvRunToolProvider.kt @@ -16,7 +16,7 @@ import kotlinx.coroutines.sync.withLock /** * PyRunToolProvider implementation that runs scripts/modules using `uv run`. */ -private class UvRunToolProvider : PyRunToolProvider { +internal class UvRunToolProvider : PyRunToolProvider { override suspend fun getRunToolParameters(): PyRunToolParameters { if (!runToolParameters.isCompleted) { diff --git a/python/src/com/jetbrains/python/uv/packaging/UvPackageRequirementsTreeExtractor.kt b/python/src/com/jetbrains/python/uv/packaging/UvPackageRequirementsTreeExtractor.kt index 8df5b6112e42..45fd8e28fee5 100644 --- a/python/src/com/jetbrains/python/uv/packaging/UvPackageRequirementsTreeExtractor.kt +++ b/python/src/com/jetbrains/python/uv/packaging/UvPackageRequirementsTreeExtractor.kt @@ -36,7 +36,7 @@ internal class UvPackageRequirementsTreeExtractor(private val uvWorkingDirectory } -private class UvPackageRequirementsTreeExtractorProvider : PythonPackageRequirementsTreeExtractorProvider { +internal class UvPackageRequirementsTreeExtractorProvider : PythonPackageRequirementsTreeExtractorProvider { override fun createExtractor(sdk: Sdk): PythonPackageRequirementsTreeExtractor? { if (!sdk.isUv) return null val data = sdk.sdkAdditionalData as? UvSdkAdditionalData ?: return null diff --git a/python/src/com/jetbrains/python/uv/packaging/UvPythonPackageRequiresExtractor.kt b/python/src/com/jetbrains/python/uv/packaging/UvPythonPackageRequiresExtractor.kt index a37cc756ab1b..9c62f6baae73 100644 --- a/python/src/com/jetbrains/python/uv/packaging/UvPythonPackageRequiresExtractor.kt +++ b/python/src/com/jetbrains/python/uv/packaging/UvPythonPackageRequiresExtractor.kt @@ -28,7 +28,7 @@ internal class UvPackageRequirementExtractor(private val uvWorkingDirectory: Pat } } -private class UvPackageRequiresExtractorProvider: PythonPackageRequiresExtractorProvider { +internal class UvPackageRequiresExtractorProvider: PythonPackageRequiresExtractorProvider { override fun createExtractor(sdk: Sdk): PythonPackageRequirementExtractor? { val data = sdk.sdkAdditionalData as? UvSdkAdditionalData ?: return null return UvPackageRequirementExtractor(data.uvWorkingDirectory) diff --git a/python/src/com/jetbrains/python/uv/sdk/evolution/UvSelectSdkProvider.kt b/python/src/com/jetbrains/python/uv/sdk/evolution/UvSelectSdkProvider.kt index 8db648962f63..b925220e1f63 100644 --- a/python/src/com/jetbrains/python/uv/sdk/evolution/UvSelectSdkProvider.kt +++ b/python/src/com/jetbrains/python/uv/sdk/evolution/UvSelectSdkProvider.kt @@ -22,7 +22,7 @@ import kotlin.collections.component1 import kotlin.collections.component2 -private class UvSelectSdkProvider() : EvoSelectSdkProvider { +internal class UvSelectSdkProvider() : EvoSelectSdkProvider { override fun getTreeElement(evoModuleSdk: EvoModuleSdk): EvoTreeLazyNodeElement { val icon = PythonCommunityImplUVCommonIcons.UV return EvoTreeLazyNodeElement("uv", icon) {