Kong / Kong/insomnia

Unable to set up dev environment in Windows 10

Open
#3,331 3 comments 0 reactions 0 assignees View on GitHub
C-question S-unverified
Dominant language
TypeScript
Stars
40k
Forks
2.4k
Avg merge
2d 13h
Merged PRs (30d)
61

Description

**Describe the bug**
I've tried several ways of setting up the project in Windows, without succeeding. The first attempt was to set up the environment as stated in the ```README.md``` by installing ```Windows build tools``` and ```node 12.18.3``` (as I need multiple node versions for different projects, I'm currently using [nvm-windows](https://github.com/coreybutler/nvm-windows). ```npm run bootstrap``` failed with the following error message:

Error log

```node
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.13 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.1.3 (node_modules\jest-haste-map\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.1.2 (node_modules\eslint-plugin-html\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

added 2273 packages from 560 contributors and audited 1599 packages in 583.219s

63 packages are looking for funding
run `npm fund` for details

found 92 vulnerabilities (4 low, 29 moderate, 59 high)
run `npm audit fix` to fix them, or `npm audit` for details
lerna notice cli v3.22.1
lerna info Bootstrapping 29 packages
lerna info Installing external dependencies
lerna ERR! npm install exited 4294963248 in 'insomnia-inso'
lerna ERR! npm install stderr:
npm WARN tarball tarball data for flow-bin@0.126.1 (sha512-RI05x7rVzruRVJQN3M4vLEjZMwUHJKhGz9FmL8HN7WiSo66/131EyJS6Vo8PkKyM2pgT9GRWfGP/tXlqS54XUg==) seems to be corrupted. Trying one more time.
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\roger\oos\insomnia\packages\insomnia-inso\node_modules\.staging\caniuse-lite-bbd738b7\data\features\gyroscope.js'
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\roger\oos\insomnia\packages\insomnia-inso\node_modules\.staging\caniuse-lite-bbd738b7\data\features\hardwareconcurrency.js'
[more ENOENT errors omited for brevity]
npm WARN insomnia-inso@2.2.33 license should be a valid SPDX license expression

npm ERR! code EPERM
npm ERR! syscall lstat
npm ERR! path C:\Users\roger\oos\insomnia\packages\insomnia-inso\node_modules\.staging\flow-bin-25972526\flow-linux64-v0.126.1\flow
npm ERR! errno -4048
npm ERR! Error: EPERM: operation not permitted, lstat 'C:\Users\roger\oos\insomnia\packages\insomnia-inso\node_modules\.staging\flow-bin-25972526\flow-linux64-v0.126.1\flow'
npm ERR! [OperationalError: EPERM: operation not permitted, lstat 'C:\Users\roger\oos\insomnia\packages\insomnia-inso\node_modules\.staging\flow-bin-25972526\flow-linux64-v0.126.1\flow'] {
npm ERR! cause: [Error: EPERM: operation not permitted, lstat 'C:\Users\roger\oos\insomnia\packages\insomnia-inso\node_modules\.staging\flow-bin-25972526\flow-linux64-v0.126.1\flow'] {
npm ERR! errno: -4048,
npm ERR! code: 'EPERM',
npm ERR! syscall: 'lstat',
npm ERR! path: 'C:\\Users\\roger\\oos\\insomnia\\packages\\insomnia-inso\\node_modules\\.staging\\flow-bin-25972526\\flow-linux64-v0.126.1\\flow'
npm ERR! },
npm ERR! errno: -4048,
npm ERR! code: 'EPERM',
npm ERR! syscall: 'lstat',
npm ERR! path: 'C:\\Users\\roger\\oos\\insomnia\\packages\\insomnia-inso\\node_modules\\.staging\\flow-bin-25972526\\flow-linux64-v0.126.1\\flow',
npm ERR! parent: 'insomnia-inso'
npm ERR! }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It's possible that the file was already in use (by a text editor or antivirus),
npm ERR! or that you lack permissions to access it.
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.
npm WARN tar ENOENT: no such file or directory, open 'C:\Users\roger\oos\insomnia\packages\insomnia-inso\node_modules\.staging\caniuse-lite-bbd738b7\data\features\getboundingclientrect.js'
[more ENOENT errors omited for brevity]
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\roger\AppData\Roaming\npm-cache\_logs\2021-04-19T12_57_30_540Z-debug.log

lerna ERR! npm install exited 4294963248 in 'insomnia-inso'
lerna WARN complete Waiting for 7 child processes to exit. CTRL-C to exit immediately.
npm ERR! code ELIFECYCLE
npm ERR! errno 4294963248
npm ERR! insomnia@1.0.0 bootstrap: `npm install && lerna bootstrap && lerna run --parallel --stream bootstrap`
npm ERR! Exit status 4294963248
npm ERR!
npm ERR! Failed at the insomnia@1.0.0 bootstrap script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\roger\AppData\Roaming\npm-cache\_logs\2021-04-19T13_03_05_582Z-debug.log

```

Note: Running ```npm run bootstrap``` with admin rights also produces the same error message.

The second attempt was done by removing all ```package-lock.json```. This solved the issues during the installation but unfortunately, after running ```npm run app-start```, the Electron application loaded on a white screen with ```CANNOT GET renderer.html``` on it. Chrome Dev Tools didn't provide much information either and the console that was running the command complained about some library installed.

The last attempt has been to install it in the Windows Linux Subsystem, after downloading all the packages needed such as ```build-essential```, ```font-manager``` and so on. The error message has been an ```EINTEGRITY``` error.

Error log

```node
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.13 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.13: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.1.3 (node_modules/jest-haste-map/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.1.2 (node_modules/eslint-plugin-html/node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.1.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

added 2273 packages from 560 contributors and audited 1599 packages in 511.007s
63 packages are looking for funding
run `npm fund` for details

found 92 vulnerabilities (4 low, 29 moderate, 59 high)
run `npm audit fix` to fix them, or `npm audit` for details

lerna notice cli v3.22.1
lerna info Bootstrapping 29 packages
lerna info Installing external dependencies
lerna ERR! npm install exited 1 in 'insomnia-inso'
lerna ERR! npm install stderr:
npm WARN tarball tarball data for flow-bin@0.126.1 (sha512-RI05x7rVzruRVJQN3M4vLEjZMwUHJKhGz9FmL8HN7WiSo66/131EyJS6Vo8PkKyM2pgT9GRWfGP/tXlqS54XUg==) seems to be corrupted. Trying one more time.
npm WARN tarball tarball data for flow-bin@0.126.1 (sha512-RI05x7rVzruRVJQN3M4vLEjZMwUHJKhGz9FmL8HN7WiSo66/131EyJS6Vo8PkKyM2pgT9GRWfGP/tXlqS54XUg==) seems to be corrupted. Trying one more time.
npm WARN insomnia-inso@2.2.33 license should be a valid SPDX license expression npm ERR! code EINTEGRITY
npm ERR! Verification failed while extracting flow-bin@0.126.1:
npm ERR! Verification failed while extracting flow-bin@0.126.1:
npm ERR! sha512-RI05x7rVzruRVJQN3M4vLEjZMwUHJKhGz9FmL8HN7WiSo66/131EyJS6Vo8PkKyM2pgT9GRWfGP/tXlqS54XUg== integrity checksum failed when using sha512: wanted sha512-RI05x7rVzruRVJQN3M4vLEjZMwUHJKhGz9FmL8HN7WiSo66/131EyJS6Vo8PkKyM2pgT9GRWfGP/tXlqS54XUg== but got sha512-Db2OujHuGCtj/gHH5Ll7vNYpd91AtnyaAIFVWkBAkPjY1Ki/eKosSW1aYdwj/JzzxTGsdzSTC8ZBiIqawkZ66Q==. (12401036 bytes) npm ERR! A complete log of this run can be found in:
npm ERR! /home/roguib/.npm/_logs/2021-04-27T17_33_56_905Z-debug.log lerna ERR! npm install exited 1 in 'insomnia-inso'
lerna WARN complete Waiting for 4 child processes to exit. CTRL-C to exit immediately
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! insomnia@1.0.0 bootstrap: `npm install && lerna bootstrap && lerna run --parallel --stream bootstrap`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the insomnia@1.0.0 bootstrap script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in:
npm ERR! /home/roguib/.npm/_logs/2021-04-27T17_34_04_740Z-debug.log

```

I've also tried to install everything using yarn just for fun, also without succeeding.

**To Reproduce**
Steps to reproduce the behavior:
1. In Windows 10, clone the repository.
2. Run ```npm run bootstrap```.
4. See error.

**Expected behavior**
Installation succeeds without exiting.

**Desktop (please complete the following information):**
- OS: Windows 10 Home

**Additional context**
Let me know if you think I could try anything else to fix this issue, I don't have anything in mind I could try.

Thanks for your help!

Contributor guide

Open the contributing guide

Research direction

Start with README.md and the npm run bootstrap entry point, then reproduce the Windows 10 failure involving lerna, flow-bin, and package installation. Compare the npm run app-start result and the reported renderer.html error across the attempted setups. Done means the documented Windows setup completes and the Electron application starts without the reported errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
electron, node.js, typescript
Domain
build-system, desktop, devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.