loopback icon indicating copy to clipboard operation
loopback copied to clipboard

Error: Cannot find module 'ieee754' - while trying to run the lb command

Open deepakparamesh opened this issue 8 years ago • 5 comments

Description/Steps to reproduce

I installed the Loopback using the command "npm install -g loopback-cli" the [email protected] was successfully installed.

after i run the command "lb" the cli threw an error

`module.js:538 throw err; ^

Error: Cannot find module 'ieee754' at Function.Module._resolveFilename (module.js:536:15) at Function.Module._load (module.js:466:25) at Module.require (module.js:579:17) at require (internal/module.js:11:18) at Object. (C:\Users\dell\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\swagger-client\dist\index.js:7:11355) at t (C:\Users\dell\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\swagger-client\dist\index.js:1:177) at Object. (C:\Users\dell\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\swagger-client\dist\index.js:7:15) at Object. (C:\Users\dell\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\swagger-client\dist\index.js:7:11111) at t (C:\Users\dell\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\swagger-client\dist\index.js:1:177) at Object. (C:\Users\dell\AppData\Roaming\npm\node_modules\loopback-cli\node_modules\swagger-client\dist\index.js:1:48717) `

Expected result

expecting the command to generate questions..

Thanks in advance

Additional information

Node version : 8.0 +

deepakparamesh avatar May 27 '18 04:05 deepakparamesh

Same issue here! Other question is, install module ieee754 globally or in dev dependencies?

diegoazh avatar May 27 '18 22:05 diegoazh

Having same issue on [email protected]

qng5150 avatar May 28 '18 02:05 qng5150

Temporary fix npm i -g ieee754 --save-dev and to get local working npm i ieee754 --save-dev

qng5150 avatar May 28 '18 02:05 qng5150

Cross posting from https://github.com/strongloop/loopback-next/issues/1367#issuecomment-392345837

swagger-api/swagger-js#1326 is the culprit.

virkt25 avatar May 28 '18 04:05 virkt25

Fixed by https://github.com/swagger-api/swagger-js/pull/1328

raymondfeng avatar May 28 '18 21:05 raymondfeng