Skip to content

Commit 641ff88

Browse files
committed
workaround for error with telemetry reporter in theia
1 parent b9ca15a commit 641ff88

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/extension.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,11 @@ async function serverManager(): Promise<any> {
363363

364364
export async function activate(context: vscode.ExtensionContext): Promise<any> {
365365
if (!packageJson.version.includes("SNAPSHOT")) {
366-
reporter = new TelemetryReporter(extensionId, extensionVersion, aiKey);
366+
try {
367+
reporter = new TelemetryReporter(extensionId, extensionVersion, aiKey);
368+
} catch (_error) {
369+
reporter = null;
370+
}
367371
}
368372

369373
const languages = packageJson.contributes.languages.map((lang) => lang.id);

0 commit comments

Comments
 (0)