-
Notifications
You must be signed in to change notification settings - Fork 29.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide stdout
and stderr
from utility process and adopt in extension host
#155987
Comments
Update: I was able to confirm that Also,
diff --git a/src/vs/platform/environment/common/environmentService.ts b/src/vs/platform/environment/common/environmentService.ts
index d90cbc60fef..32ff30de6da 100644
--- a/src/vs/platform/environment/common/environmentService.ts
+++ b/src/vs/platform/environment/common/environmentService.ts
@@ -270,7 +270,7 @@ export function parsePtyHostPort(args: NativeParsedArgs, isBuild: boolean): IDeb
function parseDebugParams(debugArg: string | undefined, debugBrkArg: string | undefined, defaultBuildPort: number, isBuild: boolean, debugId?: string, environmentString?: string): IExtensionHostDebugParams {
const portStr = debugBrkArg || debugArg;
- const port = Number(portStr) || (!isBuild ? defaultBuildPort : null);
+ const port = Number(portStr) || null;
const brk = port ? Boolean(!!debugBrkArg) : false;
let env: Record<string, string> | undefined;
if (environmentString) {
The problem is that we try to obtain the inspector port for the above action from the vscode/src/vs/workbench/services/extensions/electron-sandbox/localProcessExtensionHost.ts Lines 292 to 295 in ef65ac1
Since we current don't support stdout and stderr events for the utility process, we end up with empty inspector ports even though the inspector is started leading to failed profile action which ends up triggering the fallback. Maybe a temporary fix would be to read from the main process stdout. I will see if |
👍 . I had a brief look and it seems we listen to output and stderr not only for the purpose of obtaining the inspect port, but also to observe output and print it in general: vscode/src/vs/workbench/services/extensions/electron-sandbox/localProcessExtensionHost.ts Lines 271 to 276 in eebdf81
So I think we need this anyway, not just for debugging purposes. I wonder if this could also impact extension developers that want to log messages... |
UtilityExtensionHostProcess.enableInspectPort
does not workstdout
and stderr
stdout
and stderr
stdout
and stderr
from utility process and adopt in extension host
"extensions.experimental.useUtilityProcess": true
The text was updated successfully, but these errors were encountered: