microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
163.92k stars 29.17k forks source link

Error: Trying to add a disposable to a DisposableStore that has already been disposed of. The added object will be leaked! #232559

Open EzioLi01 opened 1 day ago

EzioLi01 commented 1 day ago

Running vscode-test on 1.95.0 occurred this issue, working well on 1.94.2.

Error: Trying to add a disposable to a DisposableStore that has already been disposed of. The added object will be leaked!
    at H3.add (file:///home/vsts/work/1/s/.vscode-test/vscode-linux-x64-1.95.0/resources/app/out/vs/workbench/api/node/extensionHostProcess.js:24:1439)
    at yw.n (file:///home/vsts/work/1/s/.vscode-test/vscode-linux-x64-1.95.0/resources/app/out/vs/workbench/api/node/extensionHostProcess.js:120:1748)

Does this issue occur when all extensions are disabled?: Yes

Steps to Reproduce:

  1. Execute unit test via test-electron in EH.
aiday-mar commented 1 day ago

From author's issue, seems to maybe be related to electron

deepak1556 commented 1 day ago

Based on the stack the error is unrelated to the runtime, it is likely from the recent logging refactor. Stack points to https://github.com/microsoft/vscode/blob/8f0188c73ff77ecc251a549e9af9b64837205fdd/src/vs/workbench/api/common/extHostOutput.ts#L168