Open MerlinFeng opened 7 years ago
Your install might have failed while installing protagonist - try npm rebuild
Having the same error after installing aglio globally.
module.js:457
throw err;
^
Error: Cannot find module 'protagonist'
at Function.Module._resolveFilename (module.js:455:15)
at Function.Module._load (module.js:403:25)
at Module.require (module.js:483:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/local/lib/node_modules/aglio/lib/main.js:9:17)
at Object.<anonymous> (/usr/local/lib/node_modules/aglio/lib/main.js:220:4)
at Module._compile (module.js:556:32)
at Object.Module._extensions..js (module.js:565:10)
at Module.load (module.js:473:32)
at tryModuleLoad (module.js:432:12)
Tried reinstalling protagonist globally and reinstalling python2. Tried npm rebuild
. No joy. Maybe depending on Drafter instead of Protagonist would be the safer choice?
Rebuilding in the directory where aglio is installed did the trick. In my case
cd /usr/local/lib/node_modules/aglio/
npm i
npm rebuild
module.js:327 throw err; ^
Error: Cannot find module 'protagonist' at Function.Module._resolveFilename (module.js:325:15) at Function.Module._load (module.js:276:25) at Module.require (module.js:353:17) at require (internal/module.js:12:17) at Object. (/root/.nvm/versions/node/v4.5.0/lib/node_modules/.aglio_npminstall/node_modules/.2.2.1@aglio/lib/main.js:9:17)
at Object. (/root/.nvm/versions/node/v4.5.0/lib/node_modules/.aglio_npminstall/node_modules/.2.2.1@aglio/lib/main.js:220:4)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)