Comments (9)
What version of npm are you using? winston is in the package.json file. Can you try:
npm ls forever
And see what the output is?
from forever.
Hi, thanks for the follow up.
Using npm version 1.0.6 and below is the output from "npm ls forever"
root@chat-burako:# npm ls forever#
npm WARN ls doesn't take positional args. Try the 'search' command
/root
├── [email protected]
├── [email protected]
├─┬ [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ └── [email protected]
├─┬ [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ ├── [email protected]
│ └─┬ [email protected]
│ └─┬ [email protected]
│ └── [email protected]
├── [email protected]
├─┬ [email protected]
│ ├── [email protected]
│ └── [email protected]
├── [email protected]
├─┬ [email protected]
│ └── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
└── [email protected]
root@chat-burako:
from forever.
My stack trace when trying to run forever:
node.js:181
throw e; // process.nextTick error, or 'error' event on first tick
^
Error: Cannot find module 'winston'
at Function._resolveFilename (module.js:320:11)
at Function._load (module.js:266:25)
at require (module.js:364:19)
at Object. (/usr/local/sbin/forever:5:15)
at Module._compile (module.js:420:26)
at Object..js (module.js:426:10)
at Module.load (module.js:336:31)
at Function._load (module.js:297:12)
at Array. (module.js:439:10)
at EventEmitter._tickCallback (node.js:173:26)
root@chat-burako:~#
from forever.
Ok, can you try this?
npm uninstall forever -g
npm uninstall forever
npm install forever -g
See if that helps? Winston is clearly installed under your /root
directory below forever as shown in your output from npm ls forever
, but npm is trying to load forever from /usr/local/sbin/forever
as shown by your stack trace.
Have you recently upgraded npm to 1.0?
from forever.
If I clone from GIT and go to the ~/forever/bin , and run ./forever, I get the same error and the stack shows it's loading from /root directory
node.js:181
throw e; // process.nextTick error, or 'error' event on first tick
^
Error: Cannot find module 'winston'
at Function._resolveFilename (module.js:320:11)
at Function._load (module.js:266:25)
at require (module.js:364:19)
at Object. (/root/forever/bin/forever:5:15)
at Module._compile (module.js:420:26)
at Object..js (module.js:426:10)
at Module.load (module.js:336:31)
at Function._load (module.js:297:12)
at Array. (module.js:439:10)
at EventEmitter._tickCallback (node.js:173:26)
root@chat-burako:~/forever/bin#
I tried the uninstall/install sequence you gave me and still get the same error. I'm not sure if I upgraded recently or not. Do you think I could try reinstalling npm?
from forever.
Getting that error is expected if you clone from git and cd to that directory because npm has not yet installed any of the dependencies. Try this:
mkdir /root/somefolder
cd /root/somefolder
git clone [email protected]:indexzero/forever.git
cd forever
npm install .
./bin/forever list
Do you still get the error after running that command sequence?
from forever.
Also, I still need to know: Have you been using npm long? Did you recently upgrade from 0.3.18 to 1.0.6? npm changed significantly for 1.0 and you should be aware of how it works:
http://blog.nodejs.org/2011/05/01/npm-1-0-released/
from forever.
@indexzero, the method to reinstall forever and run it from ./bin worked, the error no longer appears. What do you suggest, to copy the forever executable to /usr/local/sbin (and how/where would I need to copy the dependencies) or to PATH the git forever clone on my box, in order to use forever from any path in the command line?
The npm I've been using just for a couple of weeks, when I discovered socket.io and node.js when researching to develop my chat server. I don't think I went as far back as 0.3.18.
Thanks
from forever.
Have you tried reinstalling node / npm?
from forever.
Related Issues (20)
- 4.0.1 released on npmjs.com but not tagged/released on github HOT 2
- Do not send to user list
- Windows 10: current version of forever ? HOT 1
- forever/bin/monitor still keep the output log File descriptor in memory although i deleted them HOT 1
- Vulnerable dependencies on [email protected] HOT 3
- Run forever script on Windows, show processing but not forever processes running
- [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received type number (1505) HOT 3
- security fix: pin or replace `colors` dependency HOT 14
- Running the "forever list" on ubuntu showing the following output HOT 3
- stopall gets stuck sometimes
- --plain flag is ignored/does not work in forever 4.0.3 HOT 2
- latest version has vulnarable dependencies HOT 1
- Uptime format
- Issue starting multiple servers in one command
- any guide for next js 13?
- how to find the exit reason of process HOT 1
- AIX 7.3 TL 1 forever errors
- how to save old history log instead of delete.. HOT 1
- forever --version Can run, but there are errors(v4.0.3) HOT 1
- redhat 9 enterprise clean install, getting Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from forever.