Skip to content
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

Localization and Activation Failures in Theia with ms-python.python and ms-python.debugpy Plugins #14004

Closed
wenhaofan opened this issue Aug 5, 2024 · 3 comments

Comments

@wenhaofan
Copy link

Related Issue

I previously reported an issue which can be found here: #14003. I suspect the current problem might be related to this previous issue.

Bug Description:

When starting Theia with the Python and Debugpy plugins, several errors occur related to localization bundles not loading, and also failures in activating extensions due to missing functions and menus.

Steps to Reproduce:

  1. Setup Theia with ms-python.python and ms-python.debugpy plugins.
  2. Start the Theia backend.
  3. Observe the console for errors related to plugin loading and menu registration.

Expected Behavior:

The plugins should load without errors, and all localization bundles and menu contributions should be correctly loaded and registered.

Actual Behavior:

Several errors are thrown:

  • Localization bundles fail to load due to missing directories.
  • Plugin activation fails because of unregistered menu ids and missing functions in the Theia API.
  • Errors in handling promise rejections related to the test controller registration.

Additional Information:

  • Operating System: Win11
  • Theia Version: 1.52.0
  • Plugin Versions:
    • ms-python.python: 2024.12.1
    • ms-python.debugpy: 2024.8.0

Error Logs:

2024-08-05T12:15:46.930Z root ERROR Failed to load plugin localization bundles from file:///c%3A/Users/Administrator/.theia/deployedPlugins/ms-python.python-2024.12.1/extension/./l10n. Error: ENOENT: no such file or directory, scandir 'C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\l10n'
2024-08-05T12:15:46.931Z root ERROR Failed to load plugin localization bundles from file:///c%3A/Users/Administrator/.theia/deployedPlugins/ms-python.debugpy-2024.8.0/extension/./l10n. Error: ENOENT: no such file or directory, scandir 'C:\Users\Administrator.theia\deployedPlugins\ms-python.debugpy-2024.8.0\extension\l10n'
2024-08-05T12:15:46.932Z root ERROR Failed to load plugin localization bundles from file:///c%3A/Users/Administrator/.theia/deployedPlugins/ms-python.python-2024.12.1/extension/./l10n. Error: ENOENT: no such file or directory, scandir 'C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\l10n'
2024-08-05T12:15:46.932Z root INFO Deploy plugin vscode-extension://ms-python.python/: 9989.0 ms [Finished 45.080 s after backend start]
2024-08-05T12:15:46.936Z root INFO [28c32ccd-d8b1-4610-8df4-c1ea32de17ad] Waiting for backend deployment: 1.6 ms [Finished 15423.345 s after frontend start]
2024-08-05T12:15:46.936Z root INFO [be2c5e52-4259-410f-86da-424f8b64adaf] Waiting for backend deployment: 2.9 ms [Finished 21.209 s after frontend start]
2024-08-05T12:15:46.973Z root INFO [be2c5e52-4259-410f-86da-424f8b64adaf] Sync of 2 plugins: 6.0 ms [Finished 21.215 s after frontend start]
2024-08-05T12:15:46.974Z root INFO [be2c5e52-4259-410f-86da-424f8b64adaf] Loading plugin contributions
2024-08-05T12:15:46.974Z root WARN Failed to register a menu item for plugin ms-python.python contributed to issue/reporter {
command: 'python.reportIssue',
submenu: undefined,
alt: undefined,
group: undefined,
when: undefined
} Error: Could not find submenu with id issue/reporter
at u.getMenuNode (http://127.0.0.1:3000/bundle.js:2:2384051)
at http://127.0.0.1:3000/bundle.js:2:7730167
at Array.forEach ()
at f.handle (http://127.0.0.1:3000/bundle.js:2:7730056)
at http://127.0.0.1:3000/bundle.js:2:7785887
at r (http://127.0.0.1:3000/bundle.js:2:7783355)
at O.handleContributions (http://127.0.0.1:3000/bundle.js:2:7785842)
at n.handleContributions (http://127.0.0.1:3000/bundle.js:2:7567646)
at n.loadContributions (http://127.0.0.1:3000/bundle.js:2:7583690)
at n.doLoad (http://127.0.0.1:3000/bundle.js:2:7581537)
2024-08-05T12:15:46.975Z root WARN Failed to register a menu item for plugin ms-python.python contributed to editor/content {
command: 'python.createEnvironment-button',
submenu: undefined,
alt: undefined,
group: 'Python',
when: 'showCreateEnvButton && resourceLangId == pip-requirements && !virtualWorkspace && shellExecutionSupported && !inDiffEditor && !isMergeResultEditor && pythonDepsNotInstalled'
} Error: Could not find submenu with id editor/content
at u.getMenuNode (http://127.0.0.1:3000/bundle.js:2:2384051)
at http://127.0.0.1:3000/bundle.js:2:7730167
at Array.forEach ()
at f.handle (http://127.0.0.1:3000/bundle.js:2:7730056)
at http://127.0.0.1:3000/bundle.js:2:7785887
at r (http://127.0.0.1:3000/bundle.js:2:7783355)
at O.handleContributions (http://127.0.0.1:3000/bundle.js:2:7785842)
at n.handleContributions (http://127.0.0.1:3000/bundle.js:2:7567646)
at n.loadContributions (http://127.0.0.1:3000/bundle.js:2:7583690)
at n.doLoad (http://127.0.0.1:3000/bundle.js:2:7581537)
2024-08-05T12:15:46.975Z root WARN Failed to register a menu item for plugin ms-python.python contributed to editor/content {
command: 'python.createEnvironment-button',
submenu: undefined,
alt: undefined,
group: 'Python',
when: 'showCreateEnvButton && resourceFilename == pyproject.toml && pipInstallableToml && !virtualWorkspace && shellExecutionSupported && !inDiffEditor && !isMergeResultEditor && pythonDepsNotInstalled'
} Error: Could not find submenu with id editor/content
at u.getMenuNode (http://127.0.0.1:3000/bundle.js:2:2384051)
at http://127.0.0.1:3000/bundle.js:2:7730167
at Array.forEach ()
at f.handle (http://127.0.0.1:3000/bundle.js:2:7730056)
at http://127.0.0.1:3000/bundle.js:2:7785887
at r (http://127.0.0.1:3000/bundle.js:2:7783355)
at O.handleContributions (http://127.0.0.1:3000/bundle.js:2:7785842)
at n.handleContributions (http://127.0.0.1:3000/bundle.js:2:7567646)
at n.loadContributions (http://127.0.0.1:3000/bundle.js:2:7583690)
at n.doLoad (http://127.0.0.1:3000/bundle.js:2:7581537)
2024-08-05T12:15:46.975Z root WARN Failed to register a menu item for plugin ms-python.debugpy contributed to issue/reporter {
command: 'debugpy.reportIssue',
submenu: undefined,
alt: undefined,
group: undefined,
when: undefined
} Error: Could not find submenu with id issue/reporter
at u.getMenuNode (http://127.0.0.1:3000/bundle.js:2:2384051)
at http://127.0.0.1:3000/bundle.js:2:7730167
at Array.forEach ()
at f.handle (http://127.0.0.1:3000/bundle.js:2:7730056)
at http://127.0.0.1:3000/bundle.js:2:7785887
at r (http://127.0.0.1:3000/bundle.js:2:7783355)
at O.handleContributions (http://127.0.0.1:3000/bundle.js:2:7785842)
at n.handleContributions (http://127.0.0.1:3000/bundle.js:2:7567646)
at n.loadContributions (http://127.0.0.1:3000/bundle.js:2:7583690)
at n.doLoad (http://127.0.0.1:3000/bundle.js:2:7581537)
2024-08-05T12:15:46.975Z root INFO [be2c5e52-4259-410f-86da-424f8b64adaf] Load contributions of 2 plugins: 28.0 ms [Finished 21.245 s after frontend start]
2024-08-05T12:15:47.003Z root INFO [28c32ccd-d8b1-4610-8df4-c1ea32de17ad] Sync of 2 plugins: 12.9 ms [Finished 15423.358 s after frontend start]
2024-08-05T12:15:47.005Z root INFO [28c32ccd-d8b1-4610-8df4-c1ea32de17ad] Loading plugin contributions
2024-08-05T12:15:47.005Z root WARN Failed to register a menu item for plugin ms-python.python contributed to issue/reporter {
command: 'python.reportIssue',
submenu: undefined,
alt: undefined,
group: undefined,
when: undefined
} Error: Could not find submenu with id issue/reporter
at MenuModelRegistry.getMenuNode (http://127.0.0.1:3000/bundle.js:79428:23)
at http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:7435:66
at Array.forEach ()
at MenusContributionPointHandler.handle (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:7429:37)
at http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9224:71
at pushContribution (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9114:32)
at PluginContributionHandler.handleContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9224:9)
at HostedPluginSupport.handleContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:621:41)
at HostedPluginSupport.loadContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:1361:41)
at HostedPluginSupport.doLoad (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:1247:42)
2024-08-05T12:15:47.005Z root WARN Failed to register a menu item for plugin ms-python.python contributed to editor/content {
command: 'python.createEnvironment-button',
submenu: undefined,
alt: undefined,
group: 'Python',
when: 'showCreateEnvButton && resourceLangId == pip-requirements && !virtualWorkspace && shellExecutionSupported && !inDiffEditor && !isMergeResultEditor && pythonDepsNotInstalled'
} Error: Could not find submenu with id editor/content
at MenuModelRegistry.getMenuNode (http://127.0.0.1:3000/bundle.js:79428:23)
at http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:7435:66
at Array.forEach ()
at MenusContributionPointHandler.handle (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:7429:37)
at http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9224:71
at pushContribution (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9114:32)
at PluginContributionHandler.handleContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9224:9)
at HostedPluginSupport.handleContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:621:41)
at HostedPluginSupport.loadContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:1361:41)
at HostedPluginSupport.doLoad (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:1247:42)
2024-08-05T12:15:47.005Z root WARN Failed to register a menu item for plugin ms-python.python contributed to editor/content {
command: 'python.createEnvironment-button',
submenu: undefined,
alt: undefined,
group: 'Python',
when: 'showCreateEnvButton && resourceFilename == pyproject.toml && pipInstallableToml && !virtualWorkspace && shellExecutionSupported && !inDiffEditor && !isMergeResultEditor && pythonDepsNotInstalled'
} Error: Could not find submenu with id editor/content
at MenuModelRegistry.getMenuNode (http://127.0.0.1:3000/bundle.js:79428:23)
at http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:7435:66
at Array.forEach ()
at MenusContributionPointHandler.handle (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:7429:37)
at http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9224:71
at pushContribution (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9114:32)
at PluginContributionHandler.handleContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9224:9)
at HostedPluginSupport.handleContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:621:41)
at HostedPluginSupport.loadContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:1361:41)
at HostedPluginSupport.doLoad (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:1247:42)
2024-08-05T12:15:47.006Z root WARN Failed to register a menu item for plugin ms-python.debugpy contributed to issue/reporter {
command: 'debugpy.reportIssue',
submenu: undefined,
alt: undefined,
group: undefined,
when: undefined
} Error: Could not find submenu with id issue/reporter
at MenuModelRegistry.getMenuNode (http://127.0.0.1:3000/bundle.js:79428:23)
at http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:7435:66
at Array.forEach ()
at MenusContributionPointHandler.handle (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:7429:37)
at http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9224:71
at pushContribution (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9114:32)
at PluginContributionHandler.handleContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:9224:9)
at HostedPluginSupport.handleContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:621:41)
at HostedPluginSupport.loadContributions (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:1361:41)
at HostedPluginSupport.doLoad (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:1247:42)
2024-08-05T12:15:47.006Z root INFO [28c32ccd-d8b1-4610-8df4-c1ea32de17ad] Load contributions of 2 plugins: 50.7 ms [Finished 15423.410 s after frontend start]
2024-08-05T12:15:47.063Z root INFO [hosted-plugin: 42472] PLUGIN_HOST(42472): PluginManagerExtImpl/init()
2024-08-05T12:15:47.064Z root INFO [hosted-plugin: 42472] PLUGIN_HOST(42472): initializing(python@2024.12.1 with L:\Work\3d\theia-custom\lib\backend\plugin-vscode-init)
2024-08-05T12:15:47.064Z root INFO [hosted-plugin: 42472] Debugger contribution has been registered: python
2024-08-05T12:15:47.064Z root INFO [hosted-plugin: 42472] PLUGIN_HOST(42472): initializing(debugpy@2024.8.0 with L:\Work\3d\theia-custom\lib\backend\plugin-vscode-init)
2024-08-05T12:15:47.064Z root INFO [hosted-plugin: 42472] Debugger contribution has been registered: debugpy
2024-08-05T12:15:47.091Z root INFO [hosted-plugin: 42472] PLUGIN_HOST(42472): PluginManagerExtImpl/loadPlugin(C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension)
2024-08-05T12:15:47.206Z root INFO [hosted-plugin: 18628] PLUGIN_HOST(18628): PluginManagerExtImpl/init()
2024-08-05T12:15:47.208Z root ERROR [hosted-plugin: 42472] Error: spawn C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\python-env-tools\bin\pet.exe ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:286:19)
at onErrorNT (node:internal/child_process:484:16)
at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
errno: -4058,
code: 'ENOENT',
syscall: 'spawn C:\Users\Administrator\.theia\deployedPlugins\ms-python.python-2024.12.1\extension\python-env-tools\bin\pet.exe',
path: 'C:\Users\Administrator\.theia\deployedPlugins\ms-python.python-2024.12.1\extension\python-env-tools\bin\pet.exe',
spawnargs: [ 'server' ]
}
2024-08-05T12:15:47.213Z root INFO [hosted-plugin: 18628] PLUGIN_HOST(18628): initializing(python@2024.12.1 with L:\Work\3d\theia-custom\lib\backend\plugin-vscode-init)
2024-08-05T12:15:47.213Z root INFO [hosted-plugin: 18628] Debugger contribution has been registered: python
2024-08-05T12:15:47.213Z root INFO [hosted-plugin: 18628] PLUGIN_HOST(18628): initializing(debugpy@2024.8.0 with L:\Work\3d\theia-custom\lib\backend\plugin-vscode-init)
Debugger contribution has been registered: debugpy
2024-08-05T12:15:47.217Z root INFO [hosted-plugin: 18628] PLUGIN_HOST(18628): PluginManagerExtImpl/loadPlugin(C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension)
2024-08-05T12:15:47.284Z root ERROR [hosted-plugin: 42472] Activating extension 'Python' failed: TypeError: r.window.onDidStartTerminalShellExecution is not a function
at t.onDidStartTerminalShellExecution (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:338602)
at t.registerTriggerForPipInTerminal (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:662828)
at t.registerAllCreateEnvironmentFeatures (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:697793)
at t.activateFeatures (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:397935)
at C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:2593787
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async e (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:2593260)
at async C.startPlugin (L:\Work\3d\theia-custom\lib\backend\573.js:1:475037)
at async L:\Work\3d\theia-custom\lib\backend\573.js:1:472703
2024-08-05T12:15:47.285Z root ERROR [hosted-plugin: 42472] Activating extension 'Python Debugger' failed: Error: Dependent extension 'Python' failed to activate.
at L:\Work\3d\theia-custom\lib\backend\573.js:1:472568
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async C.$activatePlugin (L:\Work\3d\theia-custom\lib\backend\573.js:1:473765)
at async Promise.all (index 0)
at async C.activateBySingleEvent (L:\Work\3d\theia-custom\lib\backend\573.js:1:473667)
at async C.$activateByEvent (L:\Work\3d\theia-custom\lib\backend\573.js:1:473344)
at async C.$start (L:\Work\3d\theia-custom\lib\backend\573.js:1:471072)
at async c.handleRequest (L:\Work\3d\theia-custom\lib\backend\640.js:1:46980)
2024-08-05T12:15:47.290Z root INFO [be2c5e52-4259-410f-86da-424f8b64adaf] Starting plugins.
2024-08-05T12:15:47.290Z root INFO [be2c5e52-4259-410f-86da-424f8b64adaf] Start of 2 plugins: 311.0 ms [Finished 21.563 s after frontend start]
2024-08-05T12:15:47.341Z root ERROR [hosted-plugin: 18628] Error: spawn C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\python-env-tools\bin\pet.exe ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:286:19)
at onErrorNT (node:internal/child_process:484:16)
at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
errno: -4058,
code: 'ENOENT',
syscall: 'spawn C:\Users\Administrator\.theia\deployedPlugins\ms-python.python-2024.12.1\extension\python-env-tools\bin\pet.exe',
path: 'C:\Users\Administrator\.theia\deployedPlugins\ms-python.python-2024.12.1\extension\python-env-tools\bin\pet.exe',
spawnargs: [ 'server' ]
}
2024-08-05T12:15:47.371Z root ERROR [hosted-plugin: 18628] Activating extension 'Python' failed: TypeError: r.window.onDidStartTerminalShellExecution is not a function
at t.onDidStartTerminalShellExecution (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:338602)
at t.registerTriggerForPipInTerminal (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:662828)
at t.registerAllCreateEnvironmentFeatures (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:697793)
at t.activateFeatures (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:397935)
at C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:2593787
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async e (C:\Users\Administrator.theia\deployedPlugins\ms-python.python-2024.12.1\extension\out\client\extension.js:2:2593260)
at async C.startPlugin (L:\Work\3d\theia-custom\lib\backend\573.js:1:475037)
at async L:\Work\3d\theia-custom\lib\backend\573.js:1:472703
2024-08-05T12:15:47.372Z root ERROR [hosted-plugin: 18628] Activating extension 'Python Debugger' failed: Error: Dependent extension 'Python' failed to activate.
at L:\Work\3d\theia-custom\lib\backend\573.js:1:472568
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async C.$activatePlugin (L:\Work\3d\theia-custom\lib\backend\573.js:1:473765)
at async Promise.all (index 0)
at async C.activateBySingleEvent (L:\Work\3d\theia-custom\lib\backend\573.js:1:473667)
at async C.$activateByEvent (L:\Work\3d\theia-custom\lib\backend\573.js:1:473344)
at async C.$start (L:\Work\3d\theia-custom\lib\backend\573.js:1:471072)
at async c.handleRequest (L:\Work\3d\theia-custom\lib\backend\640.js:1:46980)
2024-08-05T12:15:47.378Z root INFO [28c32ccd-d8b1-4610-8df4-c1ea32de17ad] Starting plugins.
2024-08-05T12:15:47.378Z root INFO [28c32ccd-d8b1-4610-8df4-c1ea32de17ad] Start of 2 plugins: 365.2 ms [Finished 15423.787 s after frontend start]
2024-08-05T12:15:48.405Z root ERROR [hosted-plugin: 18628] Promise rejection not handled in one second: Error: TestController already registered: python-tests , reason: Error: TestController already registered: python-tests
2024-08-05T12:15:48.405Z root ERROR [hosted-plugin: 18628] With stack trace: Error: TestController already registered: python-tests
at DefaultTestService.registerTestController (http://127.0.0.1:3000/vendors-node_modules_theia_test_lib_browser_test-service_js.js:128:19)
at TestingMainImpl.$registerTestController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12828:86)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateTestRunProfile (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12858:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateTestRunProfile (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12858:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateTestRunProfile (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12858:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateTestRunProfile (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12858:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateTestRunProfile (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12858:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateTestRunProfile (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12858:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateTestRunProfile (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12858:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
2024-08-05T12:15:48.405Z root ERROR [hosted-plugin: 18628] With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateTestRunProfile (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12858:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12831:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found
at TestingMainImpl.withController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12843:19)
at TestingMainImpl.$updateController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12831:14)
at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)

@msujew
Copy link
Member

msujew commented Aug 5, 2024

Hey @wenhaofan,

these are effectively 4 issues:

  1. The localization errors are due to the way the extension is published on open-vsx - if the package.json declares that the extension features a localization bundle, but doesn't deliver on this promise, that's the fault of the extension publisher and not an issue on our end. Note that the backend handles this gracefully, and just ignores the declared localization bundle in that case.
  2. The missing onDidStartTerminalShellExecution function is part of (surprisingly old) VS Code's proposed API. I've created [VSCode] Support proposed.terminalShellIntegration API #14010 to track this.
  3. The missing menu endpoints are tracked in VS Code declarative API compatibility #13051
  4. The test-controller issue is already tracked in No test controller with Id ... found in test-main.ts #13211.

Note that you can install an older version of the extension (I've confirmed that 2024.10.0 works as expected) to work around the issue. I'll be closing this, since every point brought up in this issue is tracked individually in its own issue.

@msujew msujew closed this as not planned Won't fix, can't repro, duplicate, stale Aug 5, 2024
@wenhaofan
Copy link
Author

Hey @wenhaofan,

these are effectively 4 issues:

  1. The localization errors are due to the way the extension is published on open-vsx - if the package.json declares that the extension features a localization bundle, but doesn't deliver on this promise, that's the fault of the extension publisher and not an issue on our end. Note that the backend handles this gracefully, and just ignores the declared localization bundle in that case.
  2. The missing onDidStartTerminalShellExecution function is part of (surprisingly old) VS Code's proposed API. I've created [VSCode] Support proposed.terminalShellIntegration API #14010 to track this.
  3. The missing menu endpoints are tracked in VS Code declarative API compatibility #13051
  4. The test-controller issue is already tracked in No test controller with Id ... found in test-main.ts #13211.

Note that you can install an older version of the extension (I've confirmed that 2024.10.0 works as expected) to work around the issue. I'll be closing this, since every point brought up in this issue is tracked individually in its own issue.

Hello,

Thank you for recommending the installation of the older version of the extension (2024.10.0) to work around the issue. I attempted to follow your advice, but encountered some challenges:

  1. Installing via the Web Interface:
    When I tried installing the extension directly from Theia's web interface extensions, it automatically installed the latest version. Attempts to downgrade to version 2024.10.0 post-installation were unsuccessful.

  2. Using theiaPlugins Configuration:
    To circumvent the issue with the web interface, I integrated the extension directly into my project's configuration as follows:

    "theiaPlugins": {
      "ms-python": "https://open-vsx.org/api/ms-python/python/2024.10.0/file/ms-python.python-2024.10.0.vsix"
    }

    However, this approach led to build-time and runtime errors:

Build Error: No download URL for extension pack ms-python.vscode-pylance (undefined)

RuntimeError

2024-08-06T06:04:44.776Z root ERROR [hosted-plugin: 35580] Error: spawn L:\Work\3d\theia-custom\plugins\ms-python.python\extension\python-env-tools\bin\pet.exe ENOENT
    at ChildProcess._handle.onexit (node:internal/child_process:286:19)
    at onErrorNT (node:internal/child_process:484:16)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
  errno: -4058,
  code: 'ENOENT',
  syscall: 'spawn L:\\Work\\3d\\theia-custom\\plugins\\ms-python.python\\extension\\python-env-tools\\bin\\pet.exe',
  path: 'L:\\Work\\3d\\theia-custom\\plugins\\ms-python.python\\extension\\python-env-tools\\bin\\pet.exe',
  spawnargs: [ 'server' ]
}
2024-08-06T06:04:44.815Z root ERROR [hosted-plugin: 35580] Activating extension 'Python' failed: TypeError: r.window.onDidStartTerminalShellExecution is not a function
    at t.onDidStartTerminalShellExecution (L:\Work\3d\theia-custom\plugins\ms-python.python\extension\out\client\extension.js:2:338602)
    at t.registerTriggerForPipInTerminal (L:\Work\3d\theia-custom\plugins\ms-python.python\extension\out\client\extension.js:2:662828)
    at t.registerAllCreateEnvironmentFeatures (L:\Work\3d\theia-custom\plugins\ms-python.python\extension\out\client\extension.js:2:697793)
    at t.activateFeatures (L:\Work\3d\theia-custom\plugins\ms-python.python\extension\out\client\extension.js:2:397935)
    at L:\Work\3d\theia-custom\plugins\ms-python.python\extension\out\client\extension.js:2:2593787
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async e (L:\Work\3d\theia-custom\plugins\ms-python.python\extension\out\client\extension.js:2:2593260)
    at async PluginManagerExtImpl.startPlugin (L:\Work\3d\theia-custom\lib\backend\vendors-node_modules_theia_plugin-ext_lib_hosted_node_plugin-host_js.js:28619:34)
    at async L:\Work\3d\theia-custom\lib\backend\vendors-node_modules_theia_plugin-ext_lib_hosted_node_plugin-host_js.js:28519:21
2024-08-06T06:04:44.816Z root ERROR [hosted-plugin: 35580] Activating extension 'Python Debugger' failed: Error: Dependent extension 'Python' failed to activate.
    at L:\Work\3d\theia-custom\lib\backend\vendors-node_modules_theia_plugin-ext_lib_hosted_node_plugin-host_js.js:28508:43
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
2024-08-06T06:04:45.177Z root ERROR [hosted-plugin: 45964] Promise rejection not handled in one second: Error: TestController already registered: python-tests , reason: Error: TestController already registered: python-tests
With stack trace: Error: TestController already registered: python-tests
    at DefaultTestService.registerTestController (http://127.0.0.1:3000/vendors-node_modules_theia_test_lib_browser_test-service_js.js:128:19)
    at TestingMainImpl.$registerTestController (http://127.0.0.1:3000/vendors-node_modules_theia_plugin-ext_lib_hosted_browser_hosted-plugin_js.js:12828:86)    
    at http://127.0.0.1:3000/vendors-node_modules_theia_notebook_lib_common_index_js-node_modules_theia_plugin-ext_lib_com-c8361e.js:1341:71
    at async RpcProtocol.handleRequest (http://127.0.0.1:3000/bundle.js:80420:28)
2024-08-06T06:04:45.177Z root ERROR [hosted-plugin: 45964] Promise rejection not handled in one second: Error: No test controller with id python-tests found , reason: Error: No test controller with id python-tests found
With stack trace: Error: No test controller with id python-tests found

could you share how you successfully installed this specific version? Did you encounter similar errors, or are there specific steps you took to ensure a smooth installation?

I appreciate your help as I navigate these installation challenges.

Thank you!

@msujew
Copy link
Member

msujew commented Aug 6, 2024

@wenhaofan When searching for the extension in the extension view, you can open the context menu via right click to install a different version of the extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants