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
I installed and configured winston-mongodb. When I tried to run the app, it crashed. Below are the details. I tried to fix it myself on the local copy, but it contiues to fail. So, I'm sending an issue instead of generating a pull request.
What do you expect to happen instead?
The app to start and send logs to mongodb.
Error message
node .
/Users/bob/git/CPESN/Sandbox/passport_workspace/node_modules/winston-transport/index.js:32
this.once('pipe', logger => {
^
TypeError: this.once is not a function
at Object.TransportStream (/Users/bob/git/CPESN/Sandbox/passport_workspace/node_modules/winston-transport/index.js:32:8)
at Object.exports.MongoDB (/Users/bob/git/CPESN/Sandbox/passport_workspace/node_modules/winston-mongodb/lib/winston-mongodb.js:56:13)
at Object.<anonymous> (/Users/bob/git/CPESN/Sandbox/passport_workspace/logger.js:132:16)
at Module._compile (node:internal/modules/cjs/loader:1101:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
at Module.load (node:internal/modules/cjs/loader:981:32)
at Function.Module._load (node:internal/modules/cjs/loader:822:12)
at Module.require (node:internal/modules/cjs/loader:1005:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object.<anonymous> (/Users/bob/git/CPESN/Sandbox/passport_workspace/server.js:9:16)
Possible Solution:
I checked the core winston code. It includes a dependency for 'one-time'. So, I tried inserting it into my copy of winston-transport/index.js in the hopes of simply using a pull request. But, I apparently did it wrong because the code still fails. I'm willing to do the pull request if you tell me how to get it working.
Please tell us about your environment:
winston
version?winston@2
winston@3
./package.json
node -v
outputs:_v16.13.0What is the problem?
I installed and configured winston-mongodb. When I tried to run the app, it crashed. Below are the details. I tried to fix it myself on the local copy, but it contiues to fail. So, I'm sending an issue instead of generating a pull request.
What do you expect to happen instead?
The app to start and send logs to mongodb.
Error message
Possible Solution:
I checked the core winston code. It includes a dependency for 'one-time'. So, I tried inserting it into my copy of winston-transport/index.js in the hopes of simply using a pull request. But, I apparently did it wrong because the code still fails. I'm willing to do the pull request if you tell me how to get it working.
Changes I Tried
winston-transport/package.json
winston-transport/index.js
Implementation Excerpts
./server.js
./logger.js
The text was updated successfully, but these errors were encountered: