Workaround for failed installation in Windows
I think I found the culprit of this problem. In my windows box, all the npm installed module are line up nicely in the folder: "C:\Users<user>\AppData\Roaming\npm\node_modules", including:
- ijavascript
- node-gyp
- zeromq
However, the kernel complains of not finding the zmq.node in the folder: "C:\Users<user>\AppData\Roaming\npm\node_modules\ijavascript\node_modules"
So, I just copy manually the zeromq folder from [...\npm\node_modules] to [...\npm\node_modules\ijavascript\node_modules] and the kernel start working without a hitch in the notebook.
The zeromq folder was actually there, only missing the /Release folder that contains the zmq.node
In my opinion looks like just a matter of missing "/" in the path variable. The ijavascript is not supposed to have its own /node_modules/, isn't it?
As a recap, all the installation I did were:
npm install --global --production windows-build-tools --vs2015
npm install -g zeromq@5
npm install -g node-gyp
npm install -g ijavascript
ijsinstall
Good stuff guys!
Originally posted by @ozbigcat in https://github.com/n-riesco/ijavascript/issues/184#issuecomment-648099028
I've opening a new issue to give more visibility to this workaround, and because it's possibly an issue different from #184.
In my opinion looks like just a matter of missing "/" in the path variable. The ijavascript is not supposed to have its own /node_modules/, isn't it?
It's OK for npm packages to have their own node_folder. This is handled by npm.
Another possible explanation is the version of node-gyp. Your instructions above show zeromq was installed before node-gyp, and ijavascript after. Perhaps the version of node-gyp installed globally is incompatible with ijavascript.
additional info: the installation described above only be done after following the 'normal' installation and failed.
I. e: don't have node-gyp, zeromq@5 nor vs2015 before that. in other word, I am implying that maybe the work around works without having to install node-gyp by itself?
I think it is all boil down to why zeromq's "/Release" folder and its contents was missing in ijavascript's zeromq's node_module....
thanks..
Confirm workaround works (Win10). Just for clarification: content in AppData\Roaming\npm\node_modules\zeromq\build has to be copied in AppData\Roaming\npm\node_modules\ijavascript\node_modules\zeromq\build (empty)
Tested on: Windows:
Edition Windows 10 Pro for Workstations
Version 20H2
Installed on 9/8/2020
OS build 19042.804
Experience Windows Feature Experience Pack 120.2212.551.0
Environment:
node -v
v15.0.1
npm -v
7.0.3
yarn -v
1.22.5
Installation process walkthrough:
- install studio 2019 community
- add "Desktop development with C++" 2.1. manually select in "individual components" "MSVC v140 - VS 2015 C++ build tools (v14.00)"
- reboot
- run as admin powershell
- execute
npm install --global --production windows-build-tools --vs2015
npm install -g node-gyp
npm install -g zeromq@5
npm install -g ijavascript
- change policy with:
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
- run
ijsinstall
- restore policy with
Set-ExecutionPolicy -ExecutionPolicy Undefined -Scope CurrentUser
- close console.
- enjoy your new kernel.