question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error: Cannot find module '@electron/remote/main'

See original GitHub issue

Describe the issue you are having

Cannot start RIDE. When executing npm start, it errors:

- /home/xxx/Documents/Apps/ride/node_modules/electron/dist/resources/default_app.asar/main.js
- 
    at Module._resolveFilename (node:internal/modules/cjs/loader:940:15)
    at n._resolveFilename (node:electron/js2c/browser_init:249:1105)
    at Module._load (node:internal/modules/cjs/loader:785:27)
    at c._load (node:electron/js2c/asar_bundle:5:13339)
    at Module.require (node:internal/modules/cjs/loader:1012:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at Object.<anonymous> (/home/xxx/Documents/Apps/ride/main.js:6:13)
    at Module._compile (node:internal/modules/cjs/loader:1120:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1175:10)
    at Module.load (node:internal/modules/cjs/loader:988:32)
A JavaScript error occurred in the main process
Uncaught Exception:
Error: Cannot find module '@electron/remote/main'
Require stack:
- /home/xxx/Documents/Apps/ride/main.js
- /home/xxx/Documents/Apps/ride/node_modules/electron/dist/resources/default_app.asar/main.js
- 
    at Module._resolveFilename (node:internal/modules/cjs/loader:940:15)
    at n._resolveFilename (node:electron/js2c/browser_init:249:1105)
    at Module._load (node:internal/modules/cjs/loader:785:27)
    at c._load (node:electron/js2c/asar_bundle:5:13339)
    at Module.require (node:internal/modules/cjs/loader:1012:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at Object.<anonymous> (/home/xxx/Documents/Apps/ride/main.js:6:13)
    at Module._compile (node:internal/modules/cjs/loader:1120:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1175:10)
    at Module.load (node:internal/modules/cjs/loader:988:32)

Did you connect to an already running interpreter or start the interpreter from RIDE?

no

How do you reproduce the issue?

I tried building RIDE as per the instructions.

npm is installed via nvm

npm --version 8.19.2

npm version { ride45: ‘4.5.0’, npm: ‘8.19.2’, node: ‘18.10.0’, v8: ‘10.2.154.15-node.12’, uv: ‘1.43.0’, zlib: ‘1.2.11’, brotli: ‘1.0.9’, ares: ‘1.18.1’, modules: ‘108’, nghttp2: ‘1.47.0’, napi: ‘8’, llhttp: ‘6.0.10’, openssl: ‘3.0.5+quic’, cldr: ‘41.0’, icu: ‘71.1’, tz: ‘2022b’, unicode: ‘14.0’, ngtcp2: ‘0.8.1’, nghttp3: ‘0.7.0’ }

node --version v18.10.0

nvm --version 0.34.0

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
kapitaalicommented, Oct 5, 2022

Hi, the problem still persists. I did

nvm install --lts=Gallium
Installing with latest version of LTS line: Gallium
Downloading and installing node v16.17.1...
Downloading https://nodejs.org/dist/v16.17.1/node-v16.17.1-linux-x64.tar.xz...
##################################################################################### 100.0%
Computing checksum with sha256sum
Checksums matched!
Now using node v16.17.1 (npm v8.15.0)

and rm -rf node_modules and npm i

but still getting the same error message.

0reactions
kapitaalicommented, Oct 6, 2022

I now tried installing the .deb file and it seems to work fine. I just wanted you to know that there are some issues with Electron’s remote.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot find module '@electron/remote' using ... - GitHub
Hello, i have a strange behavior using @electron/remote with interceptFileProtocol: main.js const { app, ipcMain, BrowserWindow, ...
Read more >
electron Cant find module remote in the renderer process
Try with this code const app = require('electron').remote.app. And in your Main process you can do this : const {app, ipcMain, BrowserWindow ...
Read more >
@electron/remote - npm
@electron/remote is an Electron module that bridges JavaScript objects from the main process to the renderer process.
Read more >
Breaking Changes | Electron
The remote module was deprecated in Electron 12, and will be removed in ... will fail to load on Windows, with an error...
Read more >
electron/remote not bundled into final build #615 - Issuehunt
ERROR Error : Cannot find module '@electron/remote' ... Did you install 3rd party libraries used by Electron main renderer before building your app...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found