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
When I instantiate a papertrail transport, the process doesn't exit anymore. I don't even have to add it to the transports. And if I add it to transports and call close on the winston object, this happens:
node_modules\winston\lib\winston\config.js:30
else if (allColors[level].match(/\s/)) {
^
TypeError: Cannot read property 'match' of undefined
at Object.config.colorize (node_modules\winston\lib\winston\config.js:30:28)
at Papertrail.sendMessage (node_modules\winston-papertrail\lib\winston-papertrail.js:349:68)
at Papertrail.log (node_modules\winston-papertrail\lib\winston-papertrail.js:301:10)
at Transport.logException (node_modules\winston\lib\winston\transports\transport.js:134:8)
at logAndWait (node_modules\winston\lib\winston\logger.js:643:15)
at node_modules\async\lib\async.js:157:13
at _each (node_modules\async\lib\async.js:57:9)
at Object.async.each (node_modules\async\lib\async.js:156:9)
at Logger._uncaughtException (node_modules\winston\lib\winston\logger.js:666:9)
at emitOne (events.js:96:13)```
which seems to be related to Transport.logException, and when I set handleExceptions to false, I get
events.js:160
throw er; // Unhandled 'error' event
^
Error: write after end
at writeAfterEnd (_stream_writable.js:166:12)
at TLSSocket.Writable.write (_stream_writable.js:217:5)
at TLSSocket.Socket.write (net.js:643:40)
at TLSSocket.onConnected (node_modules\winston-papertrail\lib\winston-papertrail.js:228:25)
at TLSSocket.g (events.js:286:16)
at emitNone (events.js:86:13)
at TLSSocket.emit (events.js:185:7)
at TLSSocket.<anonymous> (_tls_wrap.js:1076:14)
at emitNone (events.js:86:13)
at TLSSocket.emit (events.js:185:7)
And finally, similar to #52, if I introduce a one second delay before calling close, it seems to work, but an explicit call to close is required. Do you always have to close the connection as soon as a Papertrail object exists? Something definitely remains in the event loop, since I cannot use exit or beforeExit to close it automatically.
The text was updated successfully, but these errors were encountered:
sorry for being arrogant for asking "when is this going to be fixed??",
but then in another issue, the suggested calling tr.close() on 'connect' event. i dont understand how that will help, when i want realtime logs. and this issue is causing gulp build to freeze. we have to run a build step for doing es6 to es5
When I instantiate a papertrail transport, the process doesn't exit anymore. I don't even have to add it to the transports. And if I add it to transports and call
close
on the winston object, this happens:which seems to be related to
Transport.logException
, and when I sethandleExceptions
to false, I getAnd finally, similar to #52, if I introduce a one second delay before calling
close
, it seems to work, but an explicit call to close is required. Do you always have to close the connection as soon as a Papertrail object exists? Something definitely remains in the event loop, since I cannot useexit
orbeforeExit
to close it automatically.The text was updated successfully, but these errors were encountered: