pinecone-io / sample-apps

Official Pinecone sample apps
https://docs.pinecone.io/examples/sample-apps
23 stars 8 forks source link

[Bug] <Not working on Windows> #2

Open Kareem21 opened 5 months ago

Kareem21 commented 5 months ago

Is this a new bug?

Current Behavior

Lots of issue running on windows. First I had to change the PORT location on the client to a different file, and currently struggling with the airbnb/node-memwatch node module since it won't install. I believe this guide was made for linux?

Expected Behavior

airbnb/node-memwatch should be installed when i do npm i but it keeps struggling (on the /server folder)

Steps To Reproduce

go to server folder and type npm i (when on windows)

Relevant log output

PS C:\Users\karee\Desktop\bme\realbme\dubaipol\uaelabor\namespace-notes\server> npm i
npm WARN deprecated eslint-config-standard-with-typescript@43.0.1: Please use eslint-config-love, instead.
npm ERR! code 1
npm ERR! path C:\Users\karee\Desktop\bme\realbme\dubaipol\uaelabor\namespace-notes\server\node_modules\@airbnb\node-memwatch
npm ERR! command failed
npm ERR! command C:\WINDOWS\system32\cmd.exe /d /s /c node-gyp rebuild
npm ERR! Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
npm ERR!   heapdiff.cc
npm ERR!   init.cc
npm ERR!   memwatch.cc
npm ERR! c:\users\karee\desktop\bme\realbme\dubaipol\uaelabor\namespace-notes\server\node_modules\@airbnb\node-memwatch\src\memwatch.cc(19): fatal error C1083: Cannot open include file: 'sys/time.h': No such file or directory [C:\Users\karee\Desktop\bme\realbme\dubaipol\uaelabor\namespace-notes\server\node_modules\@airbnb\node-memwatch\build\memwatch.vcxproj]
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@10.0.1
npm ERR! gyp info using node@21.5.0 | win32 | x64
npm ERR! gyp info find Python using Python version 3.10.9 found at "C:\Program Files\Python310\python.exe"
npm ERR! gyp info find VS using VS2017 (15.9.28307.1440) found at:
npm ERR! gyp info find VS "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools"
npm ERR! gyp info find VS run with --verbose for detailed information
npm ERR! gyp info spawn C:\Program Files\Python310\python.exe
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args 'C:\\Users\\karee\\AppData\\Roaming\\nvm\\v21.5.0\\node_modules\\npm\\node_modules\\node-gyp\\gyp\\gyp_main.py',
npm ERR! gyp info spawn args 'binding.gyp',
npm ERR! gyp info spawn args '-f',
npm ERR! gyp info spawn args 'msvs',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'C:\\Users\\karee\\Desktop\\bme\\realbme\\dubaipol\\uaelabor\\namespace-notes\\server\\node_modules\\@airbnb\\node-memwatch\\build\\config.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'C:\\Users\\karee\\AppData\\Roaming\\nvm\\v21.5.0\\node_modules\\npm\\node_modules\\node-gyp\\addon.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args 'C:\\Users\\karee\\AppData\\Local\\node-gyp\\Cache\\21.5.0\\include\\node\\common.gypi',
npm ERR! gyp info spawn args '-Dlibrary=shared_library',
npm ERR! gyp info spawn args '-Dvisibility=default',
npm ERR! gyp info spawn args '-Dnode_root_dir=C:\\Users\\karee\\AppData\\Local\\node-gyp\\Cache\\21.5.0',
npm ERR! gyp info spawn args '-Dnode_gyp_dir=C:\\Users\\karee\\AppData\\Roaming\\nvm\\v21.5.0\\node_modules\\npm\\node_modules\\node-gyp',
npm ERR! gyp info spawn args '-Dnode_lib_file=C:\\\\Users\\\\karee\\\\AppData\\\\Local\\\\node-gyp\\\\Cache\\\\21.5.0\\\\<(target_arch)\\\\node.lib',
npm ERR! gyp info spawn args '-Dmodule_root_dir=C:\\Users\\karee\\Desktop\\bme\\realbme\\dubaipol\\uaelabor\\namespace-notes\\server\\node_modules\\@airbnb\\node-memwatch',
npm ERR! gyp info spawn args '-Dnode_engine=v8',
npm ERR! gyp info spawn args '--depth=.',
npm ERR! gyp info spawn args '--no-parallel',
npm ERR! gyp info spawn args '--generator-output',
npm ERR! gyp info spawn args 'C:\\Users\\karee\\Desktop\\bme\\realbme\\dubaipol\\uaelabor\\namespace-notes\\server\\node_modules\\@airbnb\\node-memwatch\\build',
npm ERR! gyp info spawn args '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! gyp info spawn C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\MSBuild.exe
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args 'build\\binding.sln',
npm ERR! gyp info spawn args '/clp:Verbosity=minimal',
npm ERR! gyp info spawn args '/nologo',
npm ERR! gyp info spawn args '/p:Configuration=Release;Platform=x64'
npm ERR! gyp info spawn args ]
npm ERR! gyp ERR! build error
npm ERR! gyp ERR! stack Error: `C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\MSBuild.exe` failed with exit code: 1
npm ERR! gyp ERR! stack at ChildProcess.<anonymous> (C:\Users\karee\AppData\Roaming\nvm\v21.5.0\node_modules\npm\node_modules\node-gyp\lib\build.js:209:23)
npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:519:28)
npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:294:12)
npm ERR! gyp ERR! System Windows_NT 10.0.19045
npm ERR! gyp ERR! command "C:\\Users\\karee\\AppData\\Roaming\\nvm\\v21.5.0\\node.exe" "C:\\Users\\karee\\AppData\\Roaming\\nvm\\v21.5.0\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd C:\Users\karee\Desktop\bme\realbme\dubaipol\uaelabor\namespace-notes\server\node_modules\@airbnb\node-memwatch

Environment

- **OS**:
- **Language version**:
- **Pinecone client version**:

Additional Context

a

kylermintah commented 4 months ago

Thanks @Kareem21, node-memwatch isn't essential to the server, if you remove it as a dependency does this fix the problem for you? Thank you for flagging this.