diff --git a/python/src/com/jetbrains/python/configuration/PyActiveSdkConfigurable.java b/python/src/com/jetbrains/python/configuration/PyActiveSdkConfigurable.java index e8d2aac1426a..65af27ca9de8 100644 --- a/python/src/com/jetbrains/python/configuration/PyActiveSdkConfigurable.java +++ b/python/src/com/jetbrains/python/configuration/PyActiveSdkConfigurable.java @@ -332,6 +332,9 @@ public class PyActiveSdkConfigurable implements UnnamedConfigurable { mySdkCombo.setRenderer(new PySdkListCellRenderer(null)); final Sdk selection = selectedSdk == null ? null : myProjectSdksModel.findSdk(selectedSdk.getName()); mySdkCombo.setModel(new CollectionComboBoxModel<>(items, selection)); + // The call of `setSelectedItem` is required to notify `PyPathMappingsUiProvider` about initial setting of `Sdk` via `setModel` above + // Fragile as it is vulnerable to changes of `setSelectedItem` method in respect to processing `ActionEvent` + mySdkCombo.setSelectedItem(selection); onSdkSelected(); }