diff --git a/.idea/modules.xml b/.idea/modules.xml index aae995d68840..de5d9e59281e 100644 --- a/.idea/modules.xml +++ b/.idea/modules.xml @@ -1534,8 +1534,8 @@ - - + + diff --git a/openide/src/ru/openide/OpenIdePluginBundler.kt b/openide/src/ru/openide/OpenIdePluginBundler.kt index b67c30b6adb2..db07c8e9f5b1 100644 --- a/openide/src/ru/openide/OpenIdePluginBundler.kt +++ b/openide/src/ru/openide/OpenIdePluginBundler.kt @@ -59,7 +59,7 @@ object OpenIdePluginBundler { private fun findFragmentUrl(element: Element?, majorVersion: String): String { return element?.getChildren("plugin") - ?.firstOrNull { it.getAttributeValue("version").extractMajorVersion() == majorVersion } + ?.lastOrNull { it.getAttributeValue("version").extractMajorVersion() == majorVersion } ?.getAttributeValue("url") ?: throw RuntimeException("Amlicode plugin url not found for $majorVersion version") } diff --git a/platform/platform-impl/src/com/intellij/diagnostic/ITNReporter.kt b/platform/platform-impl/src/com/intellij/diagnostic/ITNReporter.kt index f9777923de68..0ab59e976dc8 100644 --- a/platform/platform-impl/src/com/intellij/diagnostic/ITNReporter.kt +++ b/platform/platform-impl/src/com/intellij/diagnostic/ITNReporter.kt @@ -94,15 +94,15 @@ open class ITNReporter internal constructor(private val postUrl: String?) : Erro ): Boolean { service().coroutineScope.launch { try { - val reportId = if (project != null) { + if (project != null) { withBackgroundProgress(project, DiagnosticBundle.message("title.submitting.error.report")) { - ITNProxy.sendError(errorBean, postUrl) + ITNUtils.sendError(errorBean) } } else { - ITNProxy.sendError(errorBean, postUrl) + ITNUtils.sendError(errorBean) } - onSuccess(project, reportId, callback) + onSuccess(project, callback) } catch (e: Exception) { onError(project, e, errorBean, parentComponent, callback) @@ -111,10 +111,8 @@ open class ITNReporter internal constructor(private val postUrl: String?) : Erro return true } - private fun onSuccess(project: Project?, reportId: Long, callback: (SubmittedReportInfo) -> Unit) { - val reportUrl = ITNProxy.getBrowseUrl(reportId) - callback(SubmittedReportInfo(reportUrl, reportId.toString(), SubmittedReportInfo.SubmissionStatus.NEW_ISSUE)) - + private fun onSuccess(project: Project?, callback: (SubmittedReportInfo) -> Unit) { + callback(SubmittedReportInfo(SubmittedReportInfo.SubmissionStatus.NEW_ISSUE)) if (!NOTIFY_SUCCESS_EACH_REPORT.get()) return val content = DiagnosticBundle.message("error.report.gratitude") diff --git a/platform/platform-impl/src/com/intellij/diagnostic/ITNUtils.kt b/platform/platform-impl/src/com/intellij/diagnostic/ITNUtils.kt index 03ff190b392c..1c65554fe0fa 100644 --- a/platform/platform-impl/src/com/intellij/diagnostic/ITNUtils.kt +++ b/platform/platform-impl/src/com/intellij/diagnostic/ITNUtils.kt @@ -17,11 +17,13 @@ import com.intellij.ide.ApplicationActivity import com.intellij.idea.IdeaLogger import com.intellij.openapi.application.ApplicationInfo import com.intellij.openapi.application.ApplicationManager +import com.intellij.openapi.diagnostic.IdeaLoggingEvent import com.intellij.openapi.diagnostic.Logger import com.intellij.openapi.util.SystemInfo import com.intellij.openapi.util.io.FileUtilRt import com.intellij.openapi.util.text.StringUtil import com.intellij.util.ObjectUtils +import com.intellij.util.asSafely import io.sentry.Sentry import io.sentry.SentryEvent import io.sentry.SentryLevel @@ -39,7 +41,7 @@ object ITNUtils { internal fun sendError(error: ITNProxy.ErrorBean) { val event = SentryEvent() event.level = SentryLevel.ERROR - event.throwable = (error.event as IdeaReportingEvent).data.throwable + event.throwable = (error.event).data.asSafely()?.throwable event.release = ApplicationInfo.getInstance().build.asString() event.user = User().apply { diff --git a/platform/platform-impl/src/com/intellij/ide/gdpr/ConsentOptions.java b/platform/platform-impl/src/com/intellij/ide/gdpr/ConsentOptions.java index 5514eef0d876..54be0933dabd 100644 --- a/platform/platform-impl/src/com/intellij/ide/gdpr/ConsentOptions.java +++ b/platform/platform-impl/src/com/intellij/ide/gdpr/ConsentOptions.java @@ -371,6 +371,7 @@ public final class ConsentOptions implements ModificationTracker { else { // EAP feedback consent is relevant to EA builds only allDefaults.remove(lookupConsentID(EAP_FEEDBACK_OPTION_ID)); + allDefaults.remove(AI_DATA_COLLECTION_OPTION_ID); } if (!ExceptionAutoReportUtil.isAutoReportVisible()) { diff --git a/platform/platform-impl/src/ru/openide/welcome/screen/WelcomeScreenHelper.kt b/platform/platform-impl/src/ru/openide/welcome/screen/WelcomeScreenHelper.kt index ee1a4224f4c4..5d6a7d54f669 100644 --- a/platform/platform-impl/src/ru/openide/welcome/screen/WelcomeScreenHelper.kt +++ b/platform/platform-impl/src/ru/openide/welcome/screen/WelcomeScreenHelper.kt @@ -18,6 +18,7 @@ import ru.openide.welcome.screen.editor.WelcomeScreenFile import ru.openide.welcome.screen.editor.WelcomeScreenFileSystem import ru.openide.welcome.screen.editor.WelcomeScreenFileType import com.intellij.openapi.application.invokeLater +import com.intellij.openapi.diagnostic.logger import com.intellij.openapi.extensions.PluginId import com.intellij.openapi.fileEditor.FileEditorManager import com.intellij.openapi.fileEditor.OpenFileDescriptor @@ -34,7 +35,10 @@ import ru.openide.html.* class WelcomeScreenHelper(val project: Project) { fun showWelcomeScreen() { - if (!JBCefApp.isSupported()) return + if (!JBCefApp.isSupported()) { + LOG.info("JBCef is not supported!") + return + } val editorManager = FileEditorManager.getInstance(project) val openedWelcome = editorManager.allEditors.firstOrNull(WelcomeScreenFileType::isMyEditor) @@ -49,7 +53,10 @@ class WelcomeScreenHelper(val project: Project) { } fun createModel(file: VirtualFile): HtmlCefEditorModel? { - if (!WelcomeScreenFileType.isMyFile(file)) return null + if (!WelcomeScreenFileType.isMyFile(file)) { + LOG.info("Filetype for WelcomeScreen is ${file.fileType.name}") + return null + } val htmlTemplate = HtmlEditorTemplate(TEMPLATE_NAME).apply { addParam(THEME, if (StartupUiUtil.isDarkTheme) "theme-dark" else "") } @@ -105,5 +112,6 @@ class WelcomeScreenHelper(val project: Project) { private const val SUGGESTION_QUERY_NAME = "suggestionQuery" private const val PYTHON_PLUGIN_ID = "PythonCore" private const val DOCKER_PLUGIN_ID = "ru.openide.docker" + private val LOG = logger() } } \ No newline at end of file diff --git a/platform/whatsNew/resources/intellij.platform.whatsNew.xml b/platform/whatsNew/resources/intellij.platform.whatsNew.xml index 5d30c0b3ac1e..a3a2fb0a3da6 100644 --- a/platform/whatsNew/resources/intellij.platform.whatsNew.xml +++ b/platform/whatsNew/resources/intellij.platform.whatsNew.xml @@ -1,4 +1,9 @@ + + + + + @@ -10,6 +15,6 @@ - +