You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 6, 2021. It is now read-only.
Repository navigation
This repository was archived by the owner on Apr 6, 2021. It is now read-only.
Error: Cannot find module 'optimist'
at Module._resolveFilename (module.js:547:15)
at Function.modules._resolveFilename (/home/ubuntu/c9sdk/node_modules/c9/setup_paths.js:27:16)
at Function.Module._load (module.js:474:25)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)
at main (/home/ubuntu/c9sdk/server.js:74:20)
at Object. (/home/ubuntu/c9sdk/server.js:55:5)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
@POTION4 I have tried to install npm install but I'm getting:
luis.velasco2@is-di-dev-endpoints:/var/www/html/c9sdk$ sudo npm install
npm WARN deprecated connect@2.12.0: connect 2.x series is deprecated
npm WARN deprecated ejs@1.0.0: Critical security bugs fixed in 2.5.5
npm WARN deprecated jade@0.26.3: Jade has been renamed to pug, please install the latest version of pug instead of jade
npm WARN deprecated hoek@2.16.3: The major version is no longer supported. Please update to 4.x or newer
npm ERR! code 128
npm ERR! Command failed: /usr/bin/git clone --depth=1 -q -b master https://github.com/cloud9ide/tern_from_ts.git /root/.npm/_cacache/tmp/git-clone-d384bd0d
npm ERR! fatal: could not create leading directories of '/root/.npm/_cacache/tmp/git-clone-d384bd0d': Permission denied
npm ERR!
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2018-09-14T15_55_17_757Z-debug.log
"npm install" is the problem because it wipes out node_modules leaving only the few it installs by default and nearly none of those required by c9. Doing "npm i optimist" and the rest, will eventually leave you with a few that c9 needs but don't exist elsewhere. I heard someone mention they cp'd the node_modules folder and replaced it after running the npm install but other than that... there has to be a cleaner way to do this... also the install-sdk script runs an npm install of sorts but editing this file is pointless because it does this weird thing where it gets replaced with a tmp.
I was able to get the install script to run correctly and successfully by changing that crap bit of line "$NPM -production" to "npm install npm -g" (as basically a run once because the tmp replace) but of course it still wipes out the node_modules so maybe throw some "npm i"s in afterwards...
install-sdk.sh already does npm install so no need to run that separately
just tried with a fresh git clone, ./scripts/install-sdk.sh was all that was needed, worked just fine.
npm 6, node 8
I had this problem, and I fixed it by doing 2 things:
It was on a new Linux install, and I hadn't yet installed node/npm, so when the script ran npm install, it didn't. Perhaps the install script should error out in that case?
I kept getting a tmux error related to encoding. I added en_us UTF-8 as a locale, which fixed that problem.
After that, I ran the install script again, and it worked without an issue. Sounds like when this problem arises, something is halting the npm install, or exiting before it runs.
I was finally able to uninstall and install a different way (which I had already tried when I posted previously) about a week later and it just worked.On Apr 14, 2020 8:13 PM, Laís Lima <notifications@github.com> wrote:
is it solved?
—You are receiving this because you commented.Reply to this email directly, view it on GitHub, or unsubscribe.
Activity
georgir commentedon Aug 15, 2018
have you ran
scripts/install-sdk.sh?42yeah commentedon Sep 1, 2018
maybe you should try
npm install?RodolVelasco commentedon Sep 14, 2018
@POTION4 I have tried to install
npm installbut I'm getting:What could be happening?
wgailey commentedon Nov 25, 2018
"npm install" is the problem because it wipes out node_modules leaving only the few it installs by default and nearly none of those required by c9. Doing "npm i optimist" and the rest, will eventually leave you with a few that c9 needs but don't exist elsewhere. I heard someone mention they cp'd the node_modules folder and replaced it after running the npm install but other than that... there has to be a cleaner way to do this... also the install-sdk script runs an npm install of sorts but editing this file is pointless because it does this weird thing where it gets replaced with a tmp.
I was able to get the install script to run correctly and successfully by changing that crap bit of line "$NPM -production" to "npm install npm -g" (as basically a run once because the tmp replace) but of course it still wipes out the node_modules so maybe throw some "npm i"s in afterwards...
georgir commentedon Nov 26, 2018
install-sdk.sh already does npm install so no need to run that separately
just tried with a fresh git clone, ./scripts/install-sdk.sh was all that was needed, worked just fine.
npm 6, node 8
ronaldroe commentedon Apr 28, 2019
I had this problem, and I fixed it by doing 2 things:
It was on a new Linux install, and I hadn't yet installed node/npm, so when the script ran
npm install, it didn't. Perhaps the install script should error out in that case?I kept getting a tmux error related to encoding. I added en_us UTF-8 as a locale, which fixed that problem.
After that, I ran the install script again, and it worked without an issue. Sounds like when this problem arises, something is halting the
npm install, or exiting before it runs.lalizita commentedon Apr 15, 2020
is it solved?
wgailey commentedon Apr 16, 2020