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

Error with executable of electron-builder; cannot find module '@socket.io/component-emitter' #854

Open
Thokerb opened this issue Jun 5, 2024 · 0 comments
Labels

Comments

@Thokerb
Copy link

Thokerb commented Jun 5, 2024

ElectronNET.CLI Version: 23.6.2.0

  • Version:

.Net 6
Node.JS v18.18.2

  • Target:
    electronize build /target win

When building the project with target win as portable and then trying to run it, the following error message is appearing.
There are no errors during building the application.
cannot find module '@socket.io/component-emitter'
After inspecting the created app.asar archive, the package is included.
When running electronize start, then the app is starting without problems.

Steps to Reproduce:

  1. Run electronize build /target win
  2. Try to start the portable executable
  3. Error message cannot find module '@socket.io/component-emitter' appears

Reason:

This is related to the issue electron-userland/electron-builder#8244 . I don't know the exact problem of the new electron-builder, but when switching back to version 24.13.3 of the electron-builder the application can start after building.

Intermediate solution:

Set electron-builder version to 24.13.3 locally

npm install -g electron-builder@24.13.3
npm link electron-builder

Proposed solution

Set a fixed version of electron-builder in the https://github.com/ElectronNET/Electron.NET/blob/main/src/ElectronNET.CLI/Commands/BuildCommand.cs#L201 to avoid unexpected behaviour in the future.

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

No branches or pull requests

1 participant