Skip to content
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

TypeError: callback is not a function #2

Open
abhisheksett opened this issue Mar 1, 2019 · 1 comment
Open

TypeError: callback is not a function #2

abhisheksett opened this issue Mar 1, 2019 · 1 comment

Comments

@abhisheksett
Copy link

I'm getting following error intermittently:

TypeError: callback is not a function
at Query.handleResponse (/app/node_modules/node-mysql-deadlock-retries/index.js:47:11)
at Query. (/app/node_modules/mysql/lib/Connection.js:502:10)
at Query._callback (/app/node_modules/mysql/lib/Connection.js:468:16)
at Query.Sequence.end (/app/node_modules/mysql/lib/protocol/sequences/Sequence.js:83:24)
at Query._handleFinalResultPacket (/app/node_modules/mysql/lib/protocol/sequences/Query.js:139:8)
at Query.EofPacket (/app/node_modules/mysql/lib/protocol/sequences/Query.js:123:8)
at Protocol._parsePacket (/app/node_modules/mysql/lib/protocol/Protocol.js:278:23)
at Parser.write (/app/node_modules/mysql/lib/protocol/Parser.js:76:12)
at Protocol.write (/app/node_modules/mysql/lib/protocol/Protocol.js:38:16)
at Socket. (/app/node_modules/mysql/lib/Connection.js:91:28)
at Socket. (/app/node_modules/mysql/lib/Connection.js:502:10)
at Socket.emit (events.js:182:13)
at Socket.EventEmitter.emit (domain.js:442:20)
at addChunk (_stream_readable.js:283:12)
at readableAddChunk (_stream_readable.js:264:11)
at Socket.Readable.push (_stream_readable.js:219:10)

This is causing my node server to crash. How to resolve this?

@Badestrand
Copy link
Owner

This is difficult to answer for me without seeing more code. It seems like you passed something that is not a callback as the third parameter to query.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants