diff --git a/.idea/modules.xml b/.idea/modules.xml
index 1d4ca8371574..da901b6be475 100644
--- a/.idea/modules.xml
+++ b/.idea/modules.xml
@@ -855,7 +855,7 @@
-
+
diff --git a/community-resources/resources/META-INF/IdeaPlugin.xml b/community-resources/resources/META-INF/IdeaPlugin.xml
index e3a3eee1f968..ffeaf63b27f0 100644
--- a/community-resources/resources/META-INF/IdeaPlugin.xml
+++ b/community-resources/resources/META-INF/IdeaPlugin.xml
@@ -10,7 +10,6 @@
-
@@ -19,7 +18,8 @@
-
+
+
collectProductModules(root = root, result = result)
+
+ // we don't want to allow providing product modules in any x-include, check only specific ones
+ if (root.children.any { it.name == "include" && it.getAttributeValue("href") == "/META-INF/common-ide-modules.xml" }) {
+ collectProductModules(
+ root = readXmlAsModel(context.findFileInModuleSources("intellij.platform.resources", "META-INF/common-ide-modules.xml")!!),
+ result = result,
+ )
+ }
}
withContext(Dispatchers.IO) {
- val file = context.findFileInModuleSources("intellij.platform.resources", "META-INF/PlatformLangPlugin.xml")
- file?.let { readXmlAsModel(it) }
- }?.let {
- collectProductModules(root = it, result = result)
+ collectProductModules(
+ root = readXmlAsModel(context.findFileInModuleSources("intellij.platform.resources", "META-INF/PlatformLangPlugin.xml")!!),
+ result = result,
+ )
}
return result
diff --git a/platform/platform-resources/src/META-INF/PlatformLangPlugin.xml b/platform/platform-resources/src/META-INF/PlatformLangPlugin.xml
index e13b3c0fa49b..7efd006e033d 100644
--- a/platform/platform-resources/src/META-INF/PlatformLangPlugin.xml
+++ b/platform/platform-resources/src/META-INF/PlatformLangPlugin.xml
@@ -14,9 +14,6 @@
-
-
-
diff --git a/platform/platform-resources/src/META-INF/common-ide-modules.xml b/platform/platform-resources/src/META-INF/common-ide-modules.xml
new file mode 100644
index 000000000000..712aa5ff4374
--- /dev/null
+++ b/platform/platform-resources/src/META-INF/common-ide-modules.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/python/ide-common/resources/META-INF/PyCharmCorePlugin.xml b/python/ide-common/resources/META-INF/PyCharmCorePlugin.xml
index 022ec05b7f38..4af24ce16b03 100644
--- a/python/ide-common/resources/META-INF/PyCharmCorePlugin.xml
+++ b/python/ide-common/resources/META-INF/PyCharmCorePlugin.xml
@@ -6,11 +6,11 @@
-
+