Skip to content

Commit bae8359

Browse files
authored
Merge pull request #2160 from digma-ai/urgent-error-fix
catch error in org.digma.intellij.plugin.analytics.BackendInfoHolder.…
2 parents f6ec34b + 03591f6 commit bae8359

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

ide-common/src/main/kotlin/org/digma/intellij/plugin/analytics/BackendInfoHolder.kt

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,18 @@ class BackendInfoHolder : Disposable {
7070
fun updateInBackground() {
7171
@Suppress("UnstableApiUsage")
7272
disposingScope().launch {
73-
findActiveProject()?.let {
74-
aboutRef.set(AnalyticsService.getInstance(it).about)
73+
try {
74+
75+
findActiveProject()?.let {
76+
aboutRef.set(AnalyticsService.getInstance(it).about)
77+
}
78+
79+
} catch (e: Throwable) {
80+
val isConnectionException = ExceptionUtils.isAnyConnectionException(e)
81+
82+
if (!isConnectionException) {
83+
ErrorReporter.getInstance().reportError("BackendUtilsKt.updateInBackground", e)
84+
}
7585
}
7686
}
7787
}

0 commit comments

Comments
 (0)