valeriansaliou / node-fast-ratelimit

:umbrella: Fast and efficient in-memory rate-limit for Node, used to alleviate most common DOS attacks.
https://www.npmjs.com/package/fast-ratelimit
MIT License
107 stars 18 forks source link

Error on windows npm install #9

Closed ghost closed 2 years ago

ghost commented 5 years ago

C:\Users\Marat\Desktop\drawify\node_modules\hashtable-patch-valeriansaliou>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin\....\node_modules\node-gyp\bin\node-gyp.js" configure build ) else (node "C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" configure build ) gyp ERR! configure error gyp ERR! stack Error: Command failed: C:\Python37\python.EXE -c import sys; print "%s.%s.%s" % sys.version_info[:3]; gyp ERR! stack File "", line 1 gyp ERR! stack import sys; print "%s.%s.%s" % sys.version_info[:3]; gyp ERR! stack ^ gyp ERR! stack SyntaxError: invalid syntax gyp ERR! stack gyp ERR! stack at ChildProcess.exithandler (child_process.js:289:12) gyp ERR! stack at ChildProcess.emit (events.js:182:13) gyp ERR! stack at maybeClose (internal/child_process.js:962:16) gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5) gyp ERR! System Windows_NT 10.0.17134 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" "build" gyp ERR! cwd C:\Users\Marat\Desktop\drawify\node_modules\hashtable-patch-valeriansaliou gyp ERR! node -v v10.11.0 gyp ERR! node-gyp -v v3.8.0 gyp ERR! not ok npm WARN enoent ENOENT: no such file or directory, open 'C:\Users\Marat\Desktop\drawify\package.json' npm WARN drawify No description npm WARN drawify No repository field. npm WARN drawify No README data npm WARN drawify No license field.

npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! hashtable-patch-valeriansaliou@2.1.5 install: node-gyp configure build npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the hashtable-patch-valeriansaliou@2.1.5 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\Marat\AppData\Roaming\npm-cache_logs\2018-11-02T12_06_17_338Z-debug.log

valeriansaliou commented 2 years ago

Hello there! I've fixed that in v3.0.0, using the JS-native Map object, which has as well be measured in my tests to be faster anyway. This new version does not compile any dependencies anymore, fixing this issue.