Plugins not found

I’m trying to run some plugins within my extension development environment. The plugins are downloaded fine, but the plugins are not found by Theia. My project was generated (long ago) with npm install -g yo generator-theia-extension.

The project structure is below. What’s missing? Why don’t my plugins show up?

$ tree -L 1
.
├── Makefile
├── README.md
├── appsembler-theia-extension
├── browser-app
├── docs
├── lerna.json
├── mkdocs.yml
├── node_modules
├── package.json
├── plugins
├── requirements_dev.txt
└── yarn-error.log

In browser-app:

$ tree -L 1
.
├── gen-webpack.config.js
├── index.html
├── javascript-todo-list-tutorial-master
├── lib
├── node_modules
├── package.json
├── plugins
├── src-gen
├── webpack.config.js
└── yarn-error.log

And the package.json looks like this:

{
  "private": true,
  "name": "browser-app",
  "version": "0.0.0",
  "dependencies": {
    "@theia/editor": "latest",
    "@theia/filesystem": "latest",
    "@theia/markers": "latest",
    "@theia/messages": "latest",
    "@theia/mini-browser": "latest",
    "@theia/monaco": "latest",
    "@theia/navigator": "latest",
    "@theia/plugin": "latest",
    "@theia/plugin-ext": "latest",
    "@theia/plugin-ext-vscode": "latest",
    "@theia/preferences": "latest",
    "@theia/preview": "latest",
    "@theia/process": "latest",
    "@theia/vsx-registry": "latest",
    "@theia/workspace": "latest",
    "appsembler-theia-extension": "link:../appsembler-theia-extension"
  },
  "devDependencies": {
    "@theia/cli": "latest"
  },
  "resolutions": {
    "**/@theia/core": "latest"
  },
  "scripts": {
    "prepare": "theia build --mode development",
    "start": "theia start",
    "watch": "theia build --watch --mode development",
    "plugins": "theia download:plugins"
  },
  "theia": {
    "target": "browser",
    "frontend": {
      "config": {
        "applicationName": "Appsembler Theia"
      }
    }
  },
  "theiaPluginsDir": "plugins",
  "theiaPlugins": {
    "vscode-builtin-bat": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/bat-1.39.1-prel.vsix",
    "vscode-builtin-configuration-editing": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/configuration-editing-1.39.1-prel.vsix",
    "vscode-builtin-css": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/css-1.39.1-prel.vsix",
    "vscode-builtin-html": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/html-1.39.1-prel.vsix",
    "vscode-builtin-html-language-features": "https://open-vsx.org/api/vscode/html-language-features/1.49.0/file/vscode.html-language-features-1.49.0.vsix",
    "vscode-builtin-javascript": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/javascript-1.39.1-prel.vsix",
    "vscode-builtin-json": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/json-1.39.1-prel.vsix",
    "vscode-builtin-json-language-features": "https://open-vsx.org/api/vscode/json-language-features/1.46.1/file/vscode.json-language-features-1.46.1.vsix",
    "vscode-builtin-log": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/log-1.39.1-prel.vsix",
    "vscode-builtin-markdown": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/markdown-1.39.1-prel.vsix",
    "vscode-builtin-scss": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/scss-1.39.1-prel.vsix",
    "vscode-builtin-theme-defaults": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/theme-defaults-1.39.1-prel.vsix",
    "vscode-builtin-theme-monokai": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/theme-monokai-1.39.1-prel.vsix",
    "vscode-builtin-theme-tomorrow-night-blue": "https://github.com/theia-ide/vscode-builtin-extensions/releases/download/v1.39.1-prel/theme-tomorrow-night-blue-1.39.1-prel.vsix"
  }
}

And the plugins download properly:

 in ~/appsembler-theia-extension/browser-app
$ yarn theia download:plugins
yarn run v1.22.4
$ /Users/chaz/appsembler-theia-extension/node_modules/.bin/theia download:plugins
--- downloading plugins ---
(node:59606) ExperimentalWarning: The fs.promises API is experimental
- vscode-builtin-bat: already downloaded - skipping
- vscode-builtin-configuration-editing: already downloaded - skipping
- vscode-builtin-css: already downloaded - skipping
- vscode-builtin-html: already downloaded - skipping
- vscode-builtin-html-language-features: already downloaded - skipping
- vscode-builtin-javascript: already downloaded - skipping
- vscode-builtin-json: already downloaded - skipping
- vscode-builtin-json-language-features: already downloaded - skipping
- vscode-builtin-log: already downloaded - skipping
- vscode-builtin-markdown: already downloaded - skipping
- vscode-builtin-scss: already downloaded - skipping
- vscode-builtin-theme-defaults: already downloaded - skipping
- vscode-builtin-theme-monokai: already downloaded - skipping
- vscode-builtin-theme-tomorrow-night-blue: already downloaded - skipping
✨  Done in 0.74s. 

The plugins dir:

 in ~/appsembler-theia-extension/browser-app/plugins
$ tree -L 1
.
├── vscode-builtin-bat
├── vscode-builtin-configuration-editing
├── vscode-builtin-css
├── vscode-builtin-html
├── vscode-builtin-html-language-features
├── vscode-builtin-javascript
├── vscode-builtin-json
├── vscode-builtin-json-language-features
├── vscode-builtin-log
├── vscode-builtin-markdown
├── vscode-builtin-scss
├── vscode-builtin-theme-defaults
├── vscode-builtin-theme-monokai
└── vscode-builtin-theme-tomorrow-night-blue

But when I start the app (with yarn start in the browser-app directory), the plugins are not found, and indeed they do not show up in the browser:

$ yarn start
yarn run v1.22.4
$ theia start
(node:59731) ExperimentalWarning: The fs.promises API is experimental
root INFO Configuration directory URI: 'file:///Users/chaz/.theia'
root INFO Configuring to accept webviews on '.+.webview..+' hostname.
root WARN The directory referenced by local-dir:REDACTED/plugins does not exist.
root WARN The directory referenced by local-dir:/REDACTED/extensions does not exist.
root INFO Deploy plugins list took: 3.0 ms
root INFO Theia app listening on http://localhost:3000.
root INFO [3921ffbe-fd85-4643-b6ed-37e72716f545] Sync of 0 plugins took: 14.2 ms
root INFO [3921ffbe-fd85-4643-b6ed-37e72716f545] Load contributions of 0 plugins took: 0.0 ms
root INFO [3921ffbe-fd85-4643-b6ed-37e72716f545] Start of 0 plugins took: 10.5 ms
root ERROR [nsfw-watcher: 59732] (node:59732) ExperimentalWarning: The fs.promises API is experimental

No plugins:

@briandant you need to reference the location of your plugins directory when starting the application:

Thanks for your help, @vince-fugnitto!

1 Like