5

I was trying to create package of legacy electron app using electron-packager but got an error like below. I have search several questions in stackoverflow with no luck.

electron-packager . MyApp --platform=win32 --arch=x64 --no-prune --overwrite --ignore=/node_modules

Packaging app for platform win32 x64 using electron v3.1.13
Cannot read property 'info' of undefined

Below are the installed package in the project:

+-- electron-builder@20.44.4
+-- electron-json-storage@4.1.6
+-- electron-packager@15.5.2
+-- electron-winstaller@3.0.4
+-- electron@3.1.13
+-- history@4.9.0
+-- macaddress@0.2.9
+-- moment@2.29.4
+-- node-sass@4.14.1
+-- rc-tooltip@3.7.3
+-- react-bootstrap@1.6.6
+-- react-dom@16.8.4
+-- react-redux@6.0.1
+-- react-router-dom@4.3.1
+-- react-router@4.3.1
+-- react-scripts@2.1.5
+-- react@16.8.3
`-- redux@4.0.1
Mikhael Pramodana
  • 143
  • 1
  • 1
  • 6

3 Answers3

4

electron-packager@15.5.2 caused the same issue for me. A slight downgrade to electron-packager@15.5.1 made it working again!

Gary Klasen
  • 1,001
  • 1
  • 12
  • 30
  • 1
    Thank you it can pack the app successfully and create an exe for me. But when I ran the exe it only show blank white screen, despite running perfectly well using "electron ." – Mikhael Pramodana Sep 22 '22 at 12:13
  • 1
    Glad it helped. Your follow-up issue unfortunately might be related to something else but the package version, as i do not have problems here. – Gary Klasen Sep 23 '22 at 06:56
1

Same here, electron-packager@15.5.2 caused the same issue for me.

From my side, I upgraded to electron-packager@16.0.0 to made it working again. I did not find a related issue on GitHub.

Gabriel Glenn
  • 1,174
  • 1
  • 13
  • 30
0

In the end I change tools and follow according to electron documentation about application packaging. I change to electron-forge and follow the steps. It works better than packager.

Mikhael Pramodana
  • 143
  • 1
  • 1
  • 6