ijavascript icon indicating copy to clipboard operation
ijavascript copied to clipboard

Workaround for failed installation in Windows

Open n-riesco opened this issue 5 years ago • 4 comments

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

n-riesco avatar Jun 23 '20 14:06 n-riesco

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.

n-riesco avatar Jun 23 '20 15:06 n-riesco

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..

ozbigcat avatar Jun 23 '20 22:06 ozbigcat

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)

rpalloni avatar Jan 22 '21 09:01 rpalloni

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:

  1. install studio 2019 community
  2. add "Desktop development with C++" 2.1. manually select in "individual components" "MSVC v140 - VS 2015 C++ build tools (v14.00)"
  3. reboot
  4. run as admin powershell
  5. execute
npm install --global --production windows-build-tools --vs2015
npm install -g node-gyp
npm install -g zeromq@5
npm install -g ijavascript
  1. change policy with:
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
  1. run
ijsinstall
  1. restore policy with
Set-ExecutionPolicy -ExecutionPolicy Undefined -Scope CurrentUser
  1. close console.
  2. enjoy your new kernel.

ghost avatar Feb 24 '21 00:02 ghost