bot18 icon indicating copy to clipboard operation
bot18 copied to clipboard

Build error on arm. When Zenbot compiles fine.

Open tsrnc2 opened this issue 7 years ago • 3 comments

/root/.npm/_npx/15936/lib/node_modules/bot18/node_modules/js-scrypt/lib/scrypt-async.js:4 var cpu_count = require('os').cpus().length; ^

TypeError: Cannot read property 'length' of undefined at Object. (/root/.npm/_npx/15936/lib/node_modules/bot18/node_modules/js-scrypt/lib/scrypt-async.js:4:37) at Module._compile (module.js:652:30) at Object.Module._extensions..js (module.js:663:10) at Module.load (module.js:565:32) at tryModuleLoad (module.js:505:12) at Function.Module._load (module.js:497:3) at Module.require (module.js:596:17) at require (internal/module.js:11:18) at Object. (/root/.npm/_npx/15936/lib/node_modules/bot18/node_modules/js-scrypt/index.js:2:8) at Module._compile (module.js:652:30)

tsrnc2 avatar Jul 05 '18 23:07 tsrnc2

Seems this is a known node error with arm64 and require('os').cpus().length Perhaps you could add a line to the config file so the number of cores can be set manually.

tsrnc2 avatar Jul 06 '18 00:07 tsrnc2

require('os').cpus().length; looks for logical cores rather than physical ones. That can actually cause a higher latency on multi-threaded apps as two processes share the same physical core.

GarethWright avatar Jul 06 '18 08:07 GarethWright

https://www.npmjs.com/package/physical-cpu-count

fabiosantoscode avatar Sep 11 '19 11:09 fabiosantoscode