skygragon / leetcode-cli

A cli tool to enjoy leetcode!
MIT License
3.65k stars 457 forks source link

Error: Cannot find module 'underscore' #224

Closed geofflangenderfer closed 3 years ago

geofflangenderfer commented 3 years ago

Problem Summary

cannot run cli

How to reproduce

$ ./bin/leetcode -vv
node:internal/modules/cjs/loader:927
  throw err;
  ^

Error: Cannot find module 'underscore'
Require stack:
- /home/g/work/leetcode-cli_node/lib/cli.js
- /home/g/work/leetcode-cli_node/bin/leetcode
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:924:15)
    at Function.Module._load (node:internal/modules/cjs/loader:769:27)
    at Module.require (node:internal/modules/cjs/loader:996:19)
    at require (node:internal/modules/cjs/helpers:92:18)
    at Object.<anonymous> (/home/g/work/leetcode-cli_node/lib/cli.js:2:9)
    at Module._compile (node:internal/modules/cjs/loader:1092:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1121:10)
    at Module.load (node:internal/modules/cjs/loader:972:32)
    at Function.Module._load (node:internal/modules/cjs/loader:813:14)
    at Module.require (node:internal/modules/cjs/loader:996:19) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/home/g/work/leetcode-cli_node/lib/cli.js',
    '/home/g/work/leetcode-cli_node/bin/leetcode'
  ]
}

Environment

geofflangenderfer commented 3 years ago
npm install underscore