BeepIsla / csgo-commend-bot

Commend/Report bot in NodeJS
GNU Affero General Public License v3.0
288 stars 144 forks source link

node_sqlite3.node is not a valid Win32 application. #485

Closed nanmuye closed 4 years ago

nanmuye commented 4 years ago

[1] npm install npm WARN unquirer@1.0.0 requires a peer of inquirer@^5.2.0 but none is installed. You must install peer dependencies yourself.

up to date in 0.932s [2] G:\123\csgo-commend-bot-master>node index.js internal/modules/cjs/loader.js:977 return process.dlopen(module, path.toNamespacedPath(filename)); ^

Error: \?\G:\123\csgo-commend-bot-master\node_modules\sqlite3\lib\binding\node-v72-win32-x64\node_sqlite3.node is not a valid Win32 application. \?\G:\123\csgo-commend-bot-master\node_modules\sqlite3\lib\binding\node-v72-win32-x64\node_sqlite3.node

node version: v12.9.1 It can be used in previous commendbot versions

nanmuye commented 4 years ago

C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master>npm install

sqlite3@4.2.0 install C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3 node-pre-gyp install --fallback-to-build

node-pre-gyp WARN Using request for node-pre-gyp https download node-pre-gyp WARN Pre-built binaries not installable for sqlite3@4.2.0 and node@12.9.1 (node-v72 ABI, unknown) (falling back to source compile with node-gyp) node-pre-gyp WARN Hit error read ECONNRESET Traceback (most recent call last): File "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\gyp_main.py", line 16, in sys.exit(gyp.script_main()) File "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp__init.py", line 554, in script_main return main(sys.argv[1:]) File "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp__init__.py", line 547, in main return gyp_main(args) File "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\init__.py", line 532, in gyp_main generator.GenerateOutput(flat_list, targets, data, params) File "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\generator\msvs.py", line 2009, in GenerateOutput generator_flags)) File "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\generator\msvs.py", line 944, in _GenerateProject return _GenerateMSBuildProject(project, options, version, generator_flags) File "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\generator\msvs.py", line 3390, in _GenerateMSBuildProject easy_xml.WriteXmlIfChanged(content, project.path, pretty=True, win32=True) File "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\gyp\pylib\gyp\easy_xml.py", line 123, in WriteXmlIfChanged xml_string = xml_string.decode(default_encoding).encode(encoding) UnicodeDecodeError: 'gbk' codec can't decode bytes in position 10471-10472: illegal multibyte sequence gyp ERR! configure error gyp ERR! stack Error: gyp failed with exit code: 1 gyp ERR! stack at ChildProcess.onCpExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\configure.js:344:16) gyp ERR! stack at ChildProcess.emit (events.js:209:13) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12) gyp ERR! System Windows_NT 10.0.18363 gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" "configure" "--fallback-to-build" "--module=C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3\lib\binding\node-v72-win32-x64\node_sqlite3.node" "--module_name=node_sqlite3" "--module_path=C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3\lib\binding\node-v72-win32-x64" "--napi_version=4" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v72" "--python=C:\Users\nmy\.windows-build-tools\python27\python.exe" gyp ERR! cwd C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3 gyp ERR! node -v v12.9.1 gyp ERR! node-gyp -v v5.0.3 gyp ERR! not ok node-pre-gyp ERR! build error node-pre-gyp ERR! stack Error: Failed to execute 'C:\Program Files\nodejs\node.exe C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3\lib\binding\node-v72-win32-x64\node_sqlite3.node --module_name=node_sqlite3 --module_path=C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3\lib\binding\node-v72-win32-x64 --napi_version=4 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v72 --python=C:\Users\nmy.windows-build-tools\python27\python.exe' (1) node-pre-gyp ERR! stack at ChildProcess. (C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\node-pre-gyp\lib\util\compile.js:83:29) node-pre-gyp ERR! stack at ChildProcess.emit (events.js:209:13) node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1021:16) node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5) node-pre-gyp ERR! System Windows_NT 10.0.18363 node-pre-gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\node-pre-gyp\bin\node-pre-gyp" "install" "--fallback-to-build" node-pre-gyp ERR! cwd C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3 node-pre-gyp ERR! node -v v12.9.1 node-pre-gyp ERR! node-pre-gyp -v v0.11.0 node-pre-gyp ERR! not ok Failed to execute 'C:\Program Files\nodejs\node.exe C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3\lib\binding\node-v72-win32-x64\node_sqlite3.node --module_name=node_sqlite3 --module_path=C:\Users\nmy\Desktop\csgo-commend-bot-master(1)\csgo-commend-bot-master\node_modules\sqlite3\lib\binding\node-v72-win32-x64 --napi_version=4 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v72 --python=C:\Users\nmy.windows-build-tools\python27\python.exe' (1) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! sqlite3@4.2.0 install: node-pre-gyp install --fallback-to-build npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the sqlite3@4.2.0 install 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\nmy\AppData\Roaming\npm-cache_logs\2020-06-28T17_29_00_940Z-debug.log

BeepIsla commented 4 years ago

Re-download and try using npm ci instead of npm install

BeepIsla commented 4 years ago

No reply, I assume this is solved