mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-02-05 08:06:56 +07:00
PY-61413 Freeze due to non-cancelable RA in PythonLanguageLevelPusher
Do not iterate over all files in a directory. Because PythonSdkPathCache defined by SDK and SDK can be found by a directory GitOrigin-RevId: 9575e24b9c38a3203f387e8aaea32ab28507be4c
This commit is contained in:
committed by
intellij-monorepo-bot
parent
d122d5e58d
commit
3f81ae2ba0
@@ -154,10 +154,8 @@ public final class PythonLanguageLevelPusher implements FilePropertyPusher<Langu
|
||||
if (!areLanguageLevelsCompatible(oldLanguageLevel, level) || !ProjectFileIndex.getInstance(project).isInContent(fileOrDir)) {
|
||||
PushedFilePropertiesUpdater.getInstance(project).filePropertiesChanged(fileOrDir, PythonLanguageLevelPusher::isPythonFile);
|
||||
}
|
||||
for (VirtualFile child : fileOrDir.getChildren()) {
|
||||
if (!child.isDirectory() && isPythonFile(child)) {
|
||||
clearSdkPathCache(child);
|
||||
}
|
||||
if (fileOrDir.isDirectory() || isPythonFile(fileOrDir)) {
|
||||
clearSdkPathCache(fileOrDir);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user