From 60b8611fb1d37dd0f4decfba66f96e28e460e7d2 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 10 Feb 2022 14:13:03 +0100 Subject: [PATCH] add logging for url handling (#142685) --- src/vs/code/electron-main/app.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 9c487c3475c..841d59b486c 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -801,8 +801,11 @@ export class CodeApplication extends Disposable { const app = this; const environmentService = this.environmentMainService; const productService = this.productService; + const logService = this.logService; urlService.registerHandler({ async handleURL(uri: URI, options?: IOpenURLOptions): Promise { + logService.trace('app#handleURL: ', uri.toString(true), options); + if (uri.scheme === productService.urlProtocol && uri.path === 'workspace') { uri = uri.with({ authority: 'file', @@ -818,6 +821,7 @@ export class CodeApplication extends Disposable { // Check for URIs to open in window const windowOpenableFromProtocolLink = app.getWindowOpenableFromProtocolLink(uri); + logService.trace('app#handleURL: windowOpenableFromProtocolLink = ', windowOpenableFromProtocolLink); if (windowOpenableFromProtocolLink) { const [window] = windowsMainService.open({ context: OpenContext.API,