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

Package Production - Run package installer content not show #5

Open
rahmatkruniawan opened this issue Jun 8, 2017 · 25 comments
Open
Labels

Comments

@rahmatkruniawan
Copy link

I run yarn package-win when it's done
Than have 2 file ( 1 package installer and another 1 in directory win-unpacked )
I try run Application in directory win-unpacked and working fine.
When I try to install the application that has been packaged. I just see the white screen without any content there.
Do i forget something ?

Application in directory win-unpacked

win-unoackge

Installer package
packge

@amilajack
Copy link
Owner

Run DEBUG_PROD yarn package-win so you can open devtools in production

@rahmatkruniawan
Copy link
Author

@amilajack When I have to run that command ?
If I run in console, then that show this message

'DEBUG_PROD' is not recognized as an internal or external command,
operable program or batch file.

@amilajack
Copy link
Owner

oh whoops that's my bad. Its actually DEBUG_PROD=true yarn package-win

@rahmatkruniawan
Copy link
Author

this;s error in console.log. Problem with Sqlite3 I think
packager

@amilajack
Copy link
Owner

Hmm interesting. Looks like its looking for a package.json file. Interesting how webpack didn't throw an error in advance.

@amilajack
Copy link
Owner

What are your node, npm, and electron versions? Are you cloning this project or another project?

@rahmatkruniawan
Copy link
Author

Node v.6.9.1 , yarn v.0.22.0, npm v.3.10.8 and
"electron": "^1.6.5",
"electron-builder": "^17.0.1",
"electron-devtools-installer": "^2.2.0".

@amilajack
Copy link
Owner

amilajack commented Jun 9, 2017

Hmm it seems like your electron-builder is out of date. Try bumping that to the latest version.

@rahmatkruniawan
Copy link
Author

@amilajack I have been update electron-build to 17.10.0 .
When I try re-package again user yarn package-win still got some error like before

@amilajack
Copy link
Owner

the latest version starts with a major semver of 18

@rahmatkruniawan
Copy link
Author

rahmatkruniawan commented Jun 9, 2017

@amilajack I install with version 18.7.0
And I got some error when execute yarn package-win
Here it's error :

> > electron-builder 18.7.0
> Rebuilding native production dependencies for win32:x64
> Rebuilding native dependency sqlite3
> Error: D:\AppInstaled\nodejs\node.exe exited with code 1
> Output:
> yarn run v0.22.0
> $ node-pre-gyp install --fallback-to-build
> Failed to execute 'D:\AppInstaled\nodejs\node.exe D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\app\node_modules\sqlite3\lib\binding\electron-v1.6-win32-x64\node_sqlite3.node --module_name=node_sqlite3 --module_path=D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\app\node_modules\sqlite3\lib\binding\electron-v1.6-win32-x64' (1)
> info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
> 
> Error output:
> node-pre-gyp info it worked if it ends with ok
> node-pre-gyp info using node-pre-gyp@0.6.31
> node-pre-gyp info using node@6.9.1 | win32 | x64
> node-pre-gyp info build requesting source compile
> gyp info it worked if it ends with ok
> gyp info using node-gyp@3.6.0
> gyp info using node@6.9.1 | win32 | x64
> gyp info ok
> gyp info it worked if it ends with ok
> gyp info using node-gyp@3.6.0
> gyp info using node@6.9.1 | win32 | x64
> gyp http GET https://atom.io/download/electron/v1.6.7/iojs-v1.6.7.tar.gz
> gyp http 200 https://atom.io/download/electron/v1.6.7/iojs-v1.6.7.tar.gz
> gyp http GET https://atom.io/download/electron/v1.6.7/SHASUMS256.txt
> gyp http GET https://atom.io/download/electron/v1.6.7/win-x64/iojs.lib
> gyp http GET https://atom.io/download/electron/v1.6.7/win-x86/iojs.lib
> gyp http 200 https://atom.io/download/electron/v1.6.7/SHASUMS256.txt
> gyp http 200 https://atom.io/download/electron/v1.6.7/win-x64/iojs.lib
> gyp http 200 https://atom.io/download/electron/v1.6.7/win-x86/iojs.lib
> gyp WARN install got an error, rolling back install
> gyp ERR! configure error
> gyp ERR! stack Error: read ECONNRESET
> gyp ERR! stack     at exports._errnoException (util.js:1026:11)
> gyp ERR! stack     at TLSWrap.onread (net.js:569:26)
> gyp ERR! System Windows_NT 10.0.14393
> gyp ERR! command "D:\\AppInstaled\\nodejs\\node.exe" "D:\\belajar\\facebookReactJS\\dashboard\\erb-sqlite-example\\node_modules\\node-gyp\\bin\\node-gyp.js" "configure" "--fallback-to-build" "--module=D:\\belajar\\facebookReactJS\\dashboard\\erb-sqlite-example\\app\\node_modules\\sqlite3\\lib\\binding\\electron-v1.6-win32-x64\\node_sqlite3.node" "--module_name=node_sqlite3" "--module_path=D:\\belajar\\facebookReactJS\\dashboard\\erb-sqlite-example\\app\\node_modules\\sqlite3\\lib\\binding\\electron-v1.6-win32-x64"
> gyp ERR! cwd D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\app\node_modules\sqlite3
> gyp ERR! node -v v6.9.1
> gyp ERR! node-gyp -v v3.6.0
> gyp ERR! not ok
> node-pre-gyp ERR! build error
> node-pre-gyp ERR! stack Error: Failed to execute 'D:\AppInstaled\nodejs\node.exe D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\app\node_modules\sqlite3\lib\binding\electron-v1.6-win32-x64\node_sqlite3.node --module_name=node_sqlite3 --module_path=D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\app\node_modules\sqlite3\lib\binding\electron-v1.6-win32-x64' (1)
> node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\app\node_modules\sqlite3\node_modules\node-pre-gyp\lib\util\compile.js:83:29)
> node-pre-gyp ERR! stack     at emitTwo (events.js:106:13)
> node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:191:7)
> node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:877:16)
> node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
> node-pre-gyp ERR! System Windows_NT 10.0.14393
> node-pre-gyp ERR! command "D:\\AppInstaled\\nodejs\\node.exe" "D:\\belajar\\facebookReactJS\\dashboard\\erb-sqlite-example\\app\\node_modules\\sqlite3\\node_modules\\node-pre-gyp\\bin\\node-pre-gyp" "install" "--fallback-to-build"
> node-pre-gyp ERR! cwd D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\app\node_modules\sqlite3
> node-pre-gyp ERR! node -v v6.9.1
> node-pre-gyp ERR! node-pre-gyp -v v0.6.31
> node-pre-gyp ERR! not ok
> error Command failed with exit code 1.
> 
>     at ChildProcess.childProcess.once.code (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder-util\src\util.ts:135:14)
>     at ChildProcess.g (events.js:291:16)
>     at emitTwo (events.js:106:13)
>     at ChildProcess.emit (events.js:191:7)
>     at maybeClose (internal/child_process.js:877:16)
>     at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
> From previous event:
>     at spawn (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder-util\src\util.ts:103:3)
>     at D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\src\yarn.ts:120:7
>     at runCallback (timers.js:637:20)
>     at tryOnImmediate (timers.js:610:5)
>     at processImmediate [as _immediateCallback] (timers.js:582:5)
> From previous event:
>     at D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\src\yarn.ts:118:27
> From previous event:
>     at rebuild (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\out\yarn.js:93:22)
>     at D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\src\yarn.ts:16:11
>     at next (native)
>     at runCallback (timers.js:637:20)
>     at tryOnImmediate (timers.js:610:5)
>     at processImmediate [as _immediateCallback] (timers.js:582:5)
> From previous event:
>     at installOrRebuild (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\out\yarn.js:33:21)
>     at D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\src\packager.ts:393:13
>     at next (native)
> From previous event:
>     at Packager.installAppDependencies (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\out\packager.js:475:11)
>     at D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\src\packager.ts:244:20
>     at next (native)
> From previous event:
>     at Packager.doBuild (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\out\packager.js:388:11)
>     at D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\src\packager.ts:183:52
>     at next (native)
>     at runCallback (timers.js:637:20)
>     at tryOnImmediate (timers.js:610:5)
>     at processImmediate [as _immediateCallback] (timers.js:582:5)
> From previous event:
>     at Packager.build (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\out\packager.js:283:11)
>     at D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\src\builder.ts:199:33
>     at next (native)
> From previous event:
>     at build (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\out\builder.js:70:21)
>     at Object.<anonymous> (D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\node_modules\electron-builder\out\cli\build-cli.js:71:41)
>     at Module._compile (module.js:570:32)
>     at Object.Module._extensions..js (module.js:579:10)`
>     at Module.load (module.js:487:32)
>     at tryModuleLoad (module.js:446:12)
>     at Function.Module._load (module.js:438:3)
>     at Module.runMain (module.js:604:10)
>     at run (bootstrap_node.js:394:7)
>     at startup (bootstrap_node.js:149:9)
>     at bootstrap_node.js:509:3
> error Command failed with exit code 4294967295.

@rahmatkruniawan
Copy link
Author

@amilajack I down ugrade to version
Successfully compile as before and remain the same error as the beginning.
packager

@rahmatkruniawan
Copy link
Author

@amilajack Have you found a solution to this problem?

@amilajack
Copy link
Owner

I haven't. Can you create a small project that reproduces this error? That makes it easier for me as a maintainer. Thanks

@rahmatkruniawan
Copy link
Author

rahmatkruniawan commented Jun 13, 2017

@amilajack I just clone this repo and try to package in windows.
When finished install the installer that compile before, I got same error like before (doesn't show anyhing only color background blue)
*windows 10

@rahmatkruniawan
Copy link
Author

@amilajack I think errror becasu this node-pre-gyp 😕

@amilajack
Copy link
Owner

amilajack commented Jun 22, 2017

yarn add --dev electron-rebuild in the root dir of the project
then run:

./node_modules/.bin/electron-rebuild --version=1.7.0 --force --types prod,dev,optional
./node_modules/.bin/electron-rebuild --version=1.7.0 --force --types prod,dev,optional --module-dir app

This is assuming that your electron is the latest (1.6.10 I think)

@rahmatkruniawan
Copy link
Author

@amilajack Whe running ./node_modules/.bin/electron-rebuild --version=1.7.0 --force --types prod,dev,optional
I got error

'.' is not recognized as an internal or external command,
operable program or batch file.

@amilajack
Copy link
Owner

@rahmatkruniawan
Copy link
Author

@amilajack still got this error 😢

packager

@rahmatkruniawan
Copy link
Author

@amilajack when I tried update my package use

yarn

I got some error :

yarn install v0.22.0
[1/4] Resolving packages...
[2/4] Fetching packages...
warning 7zip-bin-linux@1.1.0: The platform "win32" is incompatible with this module.
info "7zip-bin-linux@1.1.0" is an optional dependency and failed compatibility check. Excluding it from installation.
warning 7zip-bin-mac@1.0.1: The platform "win32" is incompatible with this module.
info "7zip-bin-mac@1.0.1" is an optional dependency and failed compatibility check. Excluding it from installation.
warning fsevents@1.1.1: The platform "win32" is incompatible with this module.
info "fsevents@1.1.1" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning "react-file-input@0.2.5" has incorrect peer dependency "react@0.x".
[4/4] Building fresh packages...
$ concurrently "npm run flow-typed" "npm run build-dll" "install-app-deps" "node node_modules/fbjs-scripts/node/check-dev-engines.js package.json"
[2] Installing app dependencies for arch x64 to D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\app
[3] node node_modules/fbjs-scripts/node/check-dev-engines.js package.json exited with code 0
[1]
[1] > global-logistic-network@0.11.0 build-dll D:\belajar\facebookReactJS\dashboard\erb-sqlite-example
[1] > cross-env NODE_ENV=development node --trace-warnings -r babel-register ./node_modules/webpack/bin/webpack --config webpack.config.renderer.dev.dll.js --progress --profile --colors
[1]
[0]
[0] > global-logistic-network@0.11.0 flow-typed D:\belajar\facebookReactJS\dashboard\erb-sqlite-example
[0] > rm -rf flow-typed && flow-typed install --overwrite || true
[0]
[0] 'rm' is not recognized as an internal or external command,
[0] operable program or batch file.
[0] 'true' is not recognized as an internal or external command,
[0] operable program or batch file.
[0]
[0] npm ERR! Windows_NT 10.0.14393
[0] npm ERR! argv "D:\AppInstaled\nodejs\node.exe" "D:\AppInstaled\nodejs\node_modules\npm\bin\npm-cli.js" "run" "flow-typed"
[0] npm ERR! node v6.9.1
[0] npm ERR! npm v3.10.8
[0] npm ERR! code ELIFECYCLE
[0] npm ERR! global-logistic-network@0.11.0 flow-typed: rm -rf flow-typed && flow-typed install --overwrite || true
[0] npm ERR! Exit status 1
[0] npm ERR!
[0] npm ERR! Failed at the global-logistic-network@0.11.0 flow-typed script 'rm -rf flow-typed && flow-typed install --overwrite || true'.
[0] npm ERR! Make sure you have the latest version of node.js and npm installed.
[0] npm ERR! If you do, this is most likely a problem with the react-erb-sqlite package,
[0] npm ERR! not with npm itself.
[0] npm ERR! Tell the author that this fails on your system:
[0] npm ERR! rm -rf flow-typed && flow-typed install --overwrite || true
[0] npm ERR! You can get information on how to open an issue for this project with:
[0] npm ERR! npm bugs react-erb-sqlite
[0] npm ERR! Or if that isn't available, you can get their info via:
[0] npm ERR! npm owner ls react-erb-sqlite
[0] npm ERR! There is likely additional logging output above.
[0]
[0] npm ERR! Please include the following file with any support request:
[0] npm ERR! D:\belajar\facebookReactJS\dashboard\erb-sqlite-example\npm-debug.log
[0] npm run flow-typed exited with code 1
[1] 0% compiling
[1] 10% building modules 0/1 modules 1 active dll vendor
10% buildi 10% building modules 1/2 modules 1 active external "events"

@amilajack
Copy link
Owner

This is a windows specific issue. Try running this in cmder

@rahmatkruniawan
Copy link
Author

rahmatkruniawan commented Jun 23, 2017

@amilajack I have tried itu . This's what I've got. Then I run

yarn package-win

Still got same problem, WHen I tried first time. There's no problem but I dont know why this error appears. I really have no idea how to fix this X_X
cmder

@rahmatkruniawan
Copy link
Author

rahmatkruniawan commented Jun 23, 2017

@amilajack I got the temporary solution.
I just clone this repo. Then copy all depencies and all my changed code n app/ directory (don;t forget to npm install in root direcotry and app directory).
After that, I run yarn packge-win and try installing my app via installer.
That working perfectly :)
Thanks for you help anyway. This'is only temp solutions. I think a problem is when we re-run npm install the node-gyp problem show up

@stale
Copy link

stale bot commented Jan 9, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Jan 9, 2022
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

2 participants