-
-
Notifications
You must be signed in to change notification settings - Fork 522
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 during packaging on macOS #3549
Comments
Same problem here. Pretty much the vanilla config from the vite typescript template |
I am encountering this as well. Usually for
|
Encountered the same issue here. I'm using a pretty standard configuration from the Vite TypeScript template. The problem arose when I added the dependency "@electron-forge/publisher-github": "^7.3.1". I'm running on macOS 14.1.2 (23B92). |
Same, using
|
This just work for me, but i don`t know why. const config: ForgeConfig = {
packagerConfig: {
- asar: true,
+ asar: false,
icon: './assets/icons/icon',
extraResource: ["./drizzle"],
executableName: 'dash-player',
name: 'DashPlayer',
},
.....
// Fuses are used to enable/disable various Electron functionality
// at package time, before code signing the application
new FusesPlugin({
version: FuseVersion.V1,
[FuseV1Options.RunAsNode]: false,
[FuseV1Options.EnableCookieEncryption]: true,
[FuseV1Options.EnableNodeOptionsEnvironmentVariable]: false,
- [FuseV1Options.EnableNodeCliInspectArguments]: false,
+ [FuseV1Options.EnableNodeCliInspectArguments]: true,
[FuseV1Options.EnableEmbeddedAsarIntegrityValidation]: true,
- [FuseV1Options.OnlyLoadAppFromAsar]: true,
+ [FuseV1Options.OnlyLoadAppFromAsar]: false,
}), |
A decent interim solution, but its not preferable to disable asar https://www.electronjs.org/docs/latest/tutorial/asar-archives. Also, unfortunately disabling asar leads to another error for me #3371 |
I converted my repo from electron-builder to electron-forge and somewhere along the way npm or node_modules cache was stuck. Cloning my repo in a new directory and fresh npm install fixed this issue. |
I too ran into the same issue, and after some investigation, I found that the files to be packaged into asar cannot have soft links because the path resolving algorithm is buggy. |
Potentially related to this symlink issue electron/asar#308 |
Fixed (Ref: #3592 / electron/asar#308). |
Sorry to comment on a closed issue, but I'm hoping someone might be able to tell me (a) when this might be released or (b) how I can use it before it's released. (I've tried checking out electron/forge main and yarn linking to it as described in the "Running Forge Locally" section of "Contributing" and replacing electron-forge in package.json with my local version (which I'd prefer to avoid), but the problem persisted in both cases.) |
The problem is caused by @electron/asar, so just update @electron/asar dependency |
Pre-flight checklist
Electron Forge version
7.3.1
Electron version
29.1.5
Operating system
macOs 13.0.1
Last known working Electron Forge version
No response
Expected behavior
I expect my application to package without errors
Actual behavior
I am encountering an unhandled rejection error while packaging my Electron project using electron-forge package on macOS. The error message is as follows:
❯ Packaging application
› Determining targets...
❯ Packaging for arm64 on darwin
✔ Copying files
⠋ Preparing native dependencies
The issue only occurs on macOS during the packaging process. However, the project builds and runs successfully on Windows
Steps to reproduce
Additional information
Here are the project dependencies:
node -v 18.19.1
file
forge.config.ts
file
forge.env.d.ts
file
vite.base.config.ts
file
vite.main.config.ts
vite.preload.config.ts
file
vite.renderer.config.ts
Please help me resolve this issue or provide guidance on how to further debug the problem. Thank you!
The text was updated successfully, but these errors were encountered: