'Failed to start the frontend application' using 'next' dependencies

I wanted to test something I saw in the latest unreleased version but get a ‘Failed to start the frontend application’ error.

  1. ‘yo theia-extension’ to generate new ‘Hello World’ extension
  2. Change all dependencies in browser-app package.json from ‘latest’ to ‘next’
  3. Rebuild and launch in browser
Error: Cannot apply @injectable decorator multiple times.
    index.js:66 Error: Cannot apply @injectable decorator multiple times.
    at injectable.ts:8
    at DecorateConstructor (Reflect.js:541)
    at Reflect.decorate (Reflect.js:130)
    at _decorate (decorator_utils.ts:67)
    at Object.decorate (decorator_utils.ts:89)
    at Object.../TestHelloWorld/node_modules/@theia/core/lib/browser/widgets/widget.js (widget.ts:27)
    at __webpack_require__ (bootstrap:19)
    at Object.../TestHelloWorld/node_modules/@theia/core/lib/browser/widgets/index.js (index.ts:17)
    at __webpack_require__ (bootstrap:19)
    at Object.../TestHelloWorld/node_modules/@theia/core/lib/browser/dialogs.js (dialogs.ts:20)

This happens when multiple @theia/core dependencies with different versions are installed under the node_modules. Wipe node_modules and rerun yarn. It should work.

Thanks, yes it was related to that (I forgot to also change the theia core dependency in the package file of the extension itself as well).

But now I’m seeing this behaviour again (no preferences listed) so have left a comment on github.

@jweb using the hello-world template at next the preferences are visible:

Can you confirm you are actually using a next version (about dialog), and that you removed the yarn.lock file when updating from latest to next?

Hi, I’ve tried removing yarn.lock, node_modules and other directories, but using ‘next’ I can only see preferences if I use electron and add the dependency to @theia/external-terminal.

Here’s a repo I’ve been trying with.

  • If I ‘yarn’ and ‘yarn start:electron’ from this the about dialog shows 1.15 version but no preferences are listed (likewise with start:browser)
  • I do the same after adding “@theia/external-terminal”: “next”, to electron app package.json and I see preferences
  • Removing that dependency and rebuilding doesn’t show preferences again, adding it again displays them again

I’m not sure if there’s something else I could try? I also tried removing my users .theia folder.


No preferences, no @theia/external-terminal (above image)


After adding the dependency to @theia/external-terminal

@jweb it worked for me when using the standard hello-world example, but when attempting to use a minimal set of extensions the preferences did not display:

"dependencies": {
    "@theia/core": "next",
    "@theia/editor": "next",
    "@theia/electron": "next",
    "@theia/filesystem": "next",
    "@theia/monaco": "next",
    "@theia/preferences": "next",
    "@theia/workspace": "next",
    "custom-ext": "0.0.0"
},