From babe218e5a74332002f35d942b8d5c5bf9398700 Mon Sep 17 00:00:00 2001 From: Nikolay Chashnikov Date: Fri, 14 Nov 2025 17:29:18 +0100 Subject: [PATCH] IJPL-216539 API: remove @ApiStatus.OverrideOnly annotation from ErrorReportSubmitter::getPluginDescriptor method It's ok to call this particular method from plugins to include, for example, the plugin version to the report. So the annotation is removed from the class and added to individual methods instead. GitOrigin-RevId: d005ecfaf03c7e66e38115c22226ff3488aa2bcd --- .../intellij/openapi/diagnostic/ErrorReportSubmitter.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/platform/platform-api/src/com/intellij/openapi/diagnostic/ErrorReportSubmitter.java b/platform/platform-api/src/com/intellij/openapi/diagnostic/ErrorReportSubmitter.java index d45e0c66cf17..3ec09887f562 100644 --- a/platform/platform-api/src/com/intellij/openapi/diagnostic/ErrorReportSubmitter.java +++ b/platform/platform-api/src/com/intellij/openapi/diagnostic/ErrorReportSubmitter.java @@ -22,7 +22,6 @@ import java.awt.*; * * } */ -@ApiStatus.OverrideOnly public abstract class ErrorReportSubmitter implements PluginAware { @ApiStatus.Internal public static final ExtensionPointName EP_NAME = ExtensionPointName.create("com.intellij.errorHandler"); @@ -47,11 +46,13 @@ public abstract class ErrorReportSubmitter implements PluginAware { /** * @return an action text to be used in Error Reporter user interface, e.g. "Report to JetBrains". */ + @ApiStatus.OverrideOnly public abstract @NlsActions.ActionText @NotNull String getReportActionText(); /** * @return a text of a privacy notice to be shown in the dialog (in HTML; links are allowed). */ + @ApiStatus.OverrideOnly @RequiresBackgroundThread public @DetailedDescription @Nullable String getPrivacyNoticeText() { return null; @@ -61,6 +62,7 @@ public abstract class ErrorReportSubmitter implements PluginAware { * If this reporter allows a user to identify themselves, the method should return either the name of an account that will be used * for submitting reports or an empty string. Otherwise, it should return {@code null}. */ + @ApiStatus.OverrideOnly @RequiresBackgroundThread public @Nullable String getReporterAccount() { return null; @@ -70,6 +72,7 @@ public abstract class ErrorReportSubmitter implements PluginAware { * If {@link #getReporterAccount()} returns a non-null value, this method may be called when a user wants to change a reporter account. * It is expected to be synchronous - i.e., do not return until a user finished entering their data. */ + @ApiStatus.OverrideOnly public void changeReporterAccount(@NotNull Component parentComponent) { throw new UnsupportedOperationException(); } @@ -85,6 +88,7 @@ public abstract class ErrorReportSubmitter implements PluginAware { * @param consumer a callback to be called after sending is finished (or failed). * @return {@code true} if reporting was started (must invoke {@code consumer} callback with a result), {@code false} if a report can't be sent at the moment. */ + @ApiStatus.OverrideOnly public boolean submit( @NotNull IdeaLoggingEvent @NotNull [] events, @Nullable String additionalInfo,