-
Notifications
You must be signed in to change notification settings - Fork 885
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: "fn is not a function" while setting up a pino transport via pipeline #1383
Comments
Can you provide steps to reproduce? We often need a reproducible example, e.g. some code that allows someone else to recreate your problem by just copying and pasting it. If it involves more than a couple of different file, create a new repository on GitHub and add a link to that. |
Thanks @mcollina for the quick response. Let me see if I can setup a small repo ( by removing unnecessary code) that allows to reproduce this. |
Unfortunately i'm not able to re-produce this by creating a lean docker image, but its appearing consistently on my Staging Openshift build. This may be related to how openshift is building my image and not relevant with the pino itself. I'll post updates here if i'm able to find anything more relevant Thankyou |
I am getting this error, with both example:
import pino from "pino"
import { createWriteStream as createSentryStream } from "pino-sentry/dist/transport"
const streams = []
const sentryStream = createSentryStream({
dsn: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx,
})
streams.push({
stream: sentryStream,
})
const logger = pino(
{
level: 'debug'
},
pino.multistream(streams)
)
logger.error('test') |
Looks like a problem in pino-sentry |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
I'm not able to figure out what might be going wrong here,I am trying to set up a pino transport via pipelines and I get the following error . Looks like its reaching a condition where fn remains un-initialized
Any help clues would be greatly appreciated, My apologies if sufficient detail isn't provided as posting for the 1st time
TypeError: fn is not a function
at /project/user-app/node_modules/pino/lib/worker-pipeline.js:26:26
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async Promise.all (index 0)
at async module.exports (/project/user-app/node_modules/pino/lib/worker-pipeline.js:13:19)
at async start (/project/user-app/node_modules/thread-stream/lib/worker.js:57:17)
Emitted 'error' event on ThreadStream instance at:
at destroy (/project/user-app/node_modules/thread-stream/index.js:349:12)
at Worker.onWorkerMessage (/project/user-app/node_modules/thread-stream/index.js:164:7)
at Worker.emit (events.js:315:20)
at MessagePort. (internal/worker.js:192:55)
at MessagePort.emit (events.js:315:20)
at MessagePort.onmessage (internal/worker/io.js:78:8)
at MessagePort.exports.emitMessage (internal/per_context/messageport.js:11:10)
at Worker.[kOnExit] (internal/worker.js:213:5)
at Worker..onexit (internal/worker.js:160:20)
The text was updated successfully, but these errors were encountered: