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

25.1.3 pnpm install error #8493

Closed
AiHaibara opened this issue Sep 18, 2024 · 10 comments · Fixed by develar/app-builder#138
Closed

25.1.3 pnpm install error #8493

AiHaibara opened this issue Sep 18, 2024 · 10 comments · Fixed by develar/app-builder#138

Comments

@AiHaibara
Copy link

AiHaibara commented Sep 18, 2024

  • Electron-Builder Version: 25.1.3
  • Node Version: 20.17.0
  • Electron Version:32.1.1
  • Electron Type (current, beta, nightly):current
  • Target: pnpm install

pnpm install
 WARN  10 deprecated subdependencies found: @azure/core-http@3.0.4, @npmcli/move-file@1.1.2, @npmcli/move-file@2.0.1, are-we-there-yet@3.0.1, gauge@4.0.4, glob@7.2.3, glob@8.1.0, inflight@1.0.6, npmlog@6.0.2, rimraf@3.0.2
Packages: -189

Progress: resolved 730, reused 730, downloaded 0, added 0, done

electron@1.0.0 postinstall /Users/xxx/app
electron-builder install-app-deps

• electron-builder version=25.1.3
• loaded configuration file=/Users/xxx/app/electron-builder.yml
runtime: goroutine stack exceeds 1000000000-byte limit
runtime: sp=0x14026108340 stack=[0x14026108000, 0x14046108000]
fatal error: stack overflow

runtime stack:
runtime.throw({0x102bb7efe?, 0x102544374?})
/Users/runner/hostedtoolcache/go/1.21.13/arm64/src/runtime/panic.go:1077 +0x40 fp=0x172976d50 sp=0x172976d20 pc=0x10254c520
runtime.newstack()
/Users/runner/hostedtoolcache/go/1.21.13/arm64/src/runtime/stack.go:1107 +0x458 fp=0x172976f00 sp=0x172976d50 pc=0x102566ad8
runtime.morestack()
/Users/runner/hostedtoolcache/go/1.21.13/arm64/src/runtime/asm_arm64.s:316 +0x70 fp=0x172976f00 sp=0x172976f00 pc=0x10257dd70

goroutine 1 [running]:
runtime.writeHeapBits.write({0x1400ff5ee00?, 0x0?, 0x1c?, 0x1c?}, 0x5?, 0x3?)
/Users/runner/hostedtoolcache/go/1.21.13/arm64/src/runtime/mbitmap.go:795 +0x134 fp=0x14026108340 sp=0x14026108340 pc=0x10252b434
runtime.heapBitsSetType(0x1400ff5eee0, 0x20, 0x20, 0x102f7dc40)
/Users/runner/hostedtoolcache/go/1.21.13/arm64/src/runtime/mbitmap.go:1066 +0x498 fp=0x14026108400 sp=0x14026108340 pc=0x10252bb98
runtime.mallocgc(0x20, 0x102f7dc40, 0x1)
/Users/runner/hostedtoolcache/go/1.21.13/arm64/src/runtime/malloc.go:1148 +0x588 fp=0x14026108470 sp=0x14026108400 pc=0x102523878
runtime.makeslice(0x140261084c8?, 0x102556f5c?, 0x2?)
/Users/runner/hostedtoolcache/go/1.21.13/arm64/src/runtime/slice.go:103 +0x50 fp=0x140261084a0 sp=0x14026108470 pc=0x102564750
github.com/develar/app-builder/pkg/node-modules.(*Collector).processDependencies(0x14046107ca0, 0x140003c5210, {0x14008530de0, 0x56}, 0x0, 0x140261087a0, 0x0)
/Users/runner/work/app-builder/app-builder/pkg/node-modules/nodeModuleCollector.go:143 +0x68 fp=0x14026108720 sp=0x140261084a0 pc=0x1028f3618
github.com/develar/app-builder/pkg/node-modules.(*Collector).readDependencyTree(0x14046107ca0, 0x140003c51f0)

@mmaietta
Copy link
Collaborator

@beyondkmp can you please take a look at this when you have a chance? Looks like the error is originating in app-builder/pkg/node-modules/nodeModuleCollector.go

@AiHaibara can you please provide a minimum reproducible repo for this? Then we can debug it further

@beyondkmp
Copy link
Collaborator

It appears to be an issue caused by circular dependency.

@AiHaibara
Copy link
Author

and 25.1.2 is ok for pnpm install but need to using node-linker=hoisted, otherwise running will failed after build

@beyondkmp
Copy link
Collaborator

This should be caused by #8489.
@AiHaibara can you please provide a minimum reproducible repo for this? Then we can debug it further

If you cannot provide, I can provide an app-builder file to you, Please help replace it then test.

@AiHaibara
Copy link
Author

@beyondkmp @mmaietta
some package depends on the es5-ext
make some package checking, it seems to be the package "es5-ext": "0.10.53" causing this issue
"dependencies": {
"es5-ext": "0.10.53"
},
"devDependencies": {
"electron": "32.1.0",
"electron-builder": "25.1.3"
},
"es5-ext": "0.10.53" -> "es6-symbol": "~3.1.3" -> "d": "^1.0.2" -> "es5-ext": "^0.10.64" -> "es6-symbol": "^3.1.3"

@AiHaibara
Copy link
Author

AiHaibara commented Sep 20, 2024

This should be caused by #8489. @AiHaibara can you please provide a minimum reproducible repo for this? Then we can debug it further

If you cannot provide, I can provide an app-builder file to you, Please help replace it then test.

if i build many times for the same code in 25.1.2.
sometimes it will running normally.
sometimes it still will running failed with error dialog(‘xxx is not a function' or 'cannot find xxx') after build even using node-linker=hoisted

@beyondkmp
Copy link
Collaborator

@AiHaibara deploying release v25.1.6 now. Please update when you have a chance

@AiHaibara
Copy link
Author

@AiHaibara deploying release v25.1.6 now. Please update when you have a chance

Thanks @beyondkmp , pnpm install is ok now, and I build many times, it seems can be running normally now for 5.0.0-alpha.10 or 25.1.6.

@beyondkmp
Copy link
Collaborator

beyondkmp commented Sep 27, 2024 via email

@AiHaibara
Copy link
Author

Is it possible to run normally without setting hoisted?​​​​​​​​​​​​​​​​Mark Sergovia @.>于2024年9月27日 周五下午1:36写道:

@AiHaibara https://github.com/AiHaibara deploying release v25.1.6 now. Please update when you have a chance Thanks @beyondkmp https://github.com/beyondkmp , pnpm install is ok now, and I build many times, it seems can be running normally now for 5.0.0-alpha.10 or 25.1.6. — Reply to this email directly, view it on GitHub <#8493 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJVTLF6K76WY2VSUZOY2FDZYTVGBAVCNFSM6AAAAABONNZUQSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGNZYGQZTMMJRGA . You are receiving this because you were mentioned.Message ID: @.
>

@beyondkmp
it seems also is ok for only shamefully-hoist=true without node-linker=hoisted
cause shamefully-hoist=true seems is recommend by default in electron-builder doc
i'm not tryed set both empty of these, maybe that not important?

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

Successfully merging a pull request may close this issue.

3 participants